Browse Source

Fix word counting bug.. it was matching "everything"(almost..)

Morten Brix Pedersen 25 years ago
parent
commit
54cf6c6368
1 changed files with 3 additions and 1 deletions
  1. 3 1
      pisg.pl

+ 3 - 1
pisg.pl

@@ -883,7 +883,9 @@ sub parse_words
         $words{$nick}++;
         $words{$nick}++;
         # remove uninteresting words
         # remove uninteresting words
         next unless (length($word) >= $conf->{wordlength});
         next unless (length($word) >= $conf->{wordlength});
-        next if ($word =~ /$conf->{ignorewords}/);
+        if ($conf->{ignorewords}) {
+            next if ($word =~ /$conf->{ignorewords}/);
+        }
 
 
         # ignore contractions
         # ignore contractions
         next if ($word =~ m/'..?$/);
         next if ($word =~ m/'..?$/);