}
if ($i != 0) {
- &DEBUG("Question: '$query[0]' did not exist; '$query[$i]' ($i) did");
+ &VERB("Question.pl: '$query[0]' did not exist; '$query[$i]' ($i) did",2);
}
return $result;
if (!$real and $reply =~ s/^\s*<reply>\s*//i) {
# 'are' fix.
if ($reply =~ s/^are /$lhs are /i) {
- &DEBUG("Reply.pl: el-cheapo 'are' fix executed.");
- $mhs = "are"; # what's this for?
+ &VERB("Reply.pl: el-cheapo 'are' fix executed.",2);
}
} elsif (!$real and $reply =~ s/^\s*<action>\s*(.*)/\cAACTION $1\cA/i) {
if ( &IsParam("nickServ_pass") and !$nickserv) {
&DEBUG("chanServ_ops($chan): nickserv enabled but not alive? (ircCheck)");
+ &rawout("WHO NickServ");
return 0;
}
return 0 if (exists $channels{$chan}{'o'}{$ident});
return;
}
+ if ($args[5] =~ /^nickserv$/i and !$nickserv) {
+ &DEBUG("ok... we did a who for nickserv.");
+ &rawout("PRIVMSG NickServ :IDENTIFY $param{'nickServ_pass'}");
+ }
+
$nuh{lc $args[5]} = $args[5]."!".$args[2]."\@".$args[3];
}
&latest($3 || $chan, 1);
} elsif ($what =~ /^list$/i) {
- &::DEBUG("list longcut called.");
&list();
} elsif ($what =~ /^(expire|text|desc)(\s+(.*))?$/i) {
}
} else {
- &::DEBUG("could not parse '$what'.");
+ &::DEBUG("could not parse '$what'");
&::notice($::who, "unknown command: $what");
}
}
close NEWS;
my $cn = scalar(keys %::news);
- &::status("News: Read $ci items for $cn chans, $cu users cache")
- if ($ci or $cn or $cu);
+ &::status("News: Read ".
+ $ci. &::fixPlural(" item", $ci). " for ".
+ $cn. &::fixPlural(" chan", $cn). ", ".
+ $cu. &::fixPlural(" user", $cu), " cache"
+ ) if ($ci or $cn or $cu);
}
sub writeNews {
&::DEBUG("gNI: part_string->full_string: $what->$items[0]");
return $items[0];
} else {
- &::DEBUG("gNI: No match.");
+ &::DEBUG("gNI: No match for '$what'");
return;
}
}
my $startString = scalar(localtime $^T);
my $upString = &Time2String(time() - $^T);
my $count = &countKeys("factoids");
+ $count{'Commands'} = 0;
+ foreach (keys %cmdstats) {
+ $count{'Commands'} += $cmdstats{$_};
+ }
&pSReply(
"Since $startString, there have been".
&fixPlural("dunno",$count{'Dunno'}).
" and \002$count{'Moron'}\002 ".
&fixPlural("moron",$count{'Moron'}).
+ " and \002$count{'Commands'}\002 ".
+ &fixPlural("command",$count{'Commands'}).
". I have been awake for $upString this session, and ".
"currently reference \002$count\002 factoids. ".
"I'm using about \002$memusage\002 ".