This is an automated email from the ASF dual-hosted git repository.

snagel pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nutch.git

commit 4592eb695edd0b032dbf37678039368925b3c47d
Author: YossiTamari <[email protected]>
AuthorDate: Wed Nov 8 17:55:00 2017 +0200

    Fix for previous commit
---
 src/java/org/apache/nutch/indexer/IndexerMapReduce.java | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/java/org/apache/nutch/indexer/IndexerMapReduce.java 
b/src/java/org/apache/nutch/indexer/IndexerMapReduce.java
index 7e3438c..00829c4 100644
--- a/src/java/org/apache/nutch/indexer/IndexerMapReduce.java
+++ b/src/java/org/apache/nutch/indexer/IndexerMapReduce.java
@@ -238,16 +238,16 @@ public class IndexerMapReduce extends Configured 
implements
     }
 
     // Whether to delete GONE or REDIRECTS
-    if (delete) {
-      if (fetchDatum != null && fetchDatum.getStatus() == 
CrawlDatum.STATUS_FETCH_GONE
+    if (delete && fetchDatum != null) {
+      if (fetchDatum.getStatus() == CrawlDatum.STATUS_FETCH_GONE
           || dbDatum != null && dbDatum.getStatus() == 
CrawlDatum.STATUS_DB_GONE) {
         reporter.incrCounter("IndexerStatus", "deleted (gone)", 1);
         output.collect(key, DELETE_ACTION);
         return;
       }
 
-      if (fetchDatum != null && fetchDatum.getStatus() == 
CrawlDatum.STATUS_FETCH_REDIR_PERM
-          || fetchDatum != null && fetchDatum.getStatus() == 
CrawlDatum.STATUS_FETCH_REDIR_TEMP
+      if (fetchDatum.getStatus() == CrawlDatum.STATUS_FETCH_REDIR_PERM
+          || fetchDatum.getStatus() == CrawlDatum.STATUS_FETCH_REDIR_TEMP
           || dbDatum != null && dbDatum.getStatus() == 
CrawlDatum.STATUS_DB_REDIR_PERM
           || dbDatum != null && dbDatum.getStatus() == 
CrawlDatum.STATUS_DB_REDIR_TEMP) {
         reporter.incrCounter("IndexerStatus", "deleted (redirects)", 1);

-- 
To stop receiving notification emails like this one, please contact
"[email protected]" <[email protected]>.

Reply via email to