- "INIC: invalid chan"... perlness hits back.
- more misc shit.
git-svn-id: https://svn.code.sf.net/p/infobot/code/trunk/blootbot@612
c11ca15a-4712-0410-83d8-
924469b57eb5
+# &::msg($who, "News is disabled for $chan");
&::DEBUG("news: something went really wrong.");
&::DEBUG("news: something went really wrong.");
- &::DEBUG("news: chan => $chan, ::chan => $::chan");
-# &::notice($who, "something went really wrong.");
+ &::DEBUG("news: chan => $chan.");
# scalar @new, !$flag
my $unread = scalar @new;
my $total = scalar keys %{ $::news{$chan} };
# scalar @new, !$flag
my $unread = scalar @new;
my $total = scalar keys %{ $::news{$chan} };
+ if (!$flag || &::IsChanConf("newsTellUnread")) {
return unless ($unread);
# just a temporary measure not to flood ourself off the
return unless ($unread);
# just a temporary measure not to flood ourself off the
my($what) = @_;
my $item = 0;
my($what) = @_;
my $item = 0;
+ $what =~ s/^\#//; # '#1' for example.
+
my %time;
foreach (keys %{ $::news{$chan} }) {
my $t = $::news{$chan}{$_}{Time};
my %time;
foreach (keys %{ $::news{$chan} }) {
my $t = $::news{$chan}{$_}{Time};
my $found = 0;
foreach (keys %channels) {
my $found = 0;
foreach (keys %channels) {
+ # don't test for $channel{_default} elsewhere !!!
+ next if (/^\s*$/ || /^_?default$/);
next unless (&IsNickInChan($who,$_));
$found++;
next unless (&IsNickInChan($who,$_));
$found++;
&shutdown() if (defined $shm and defined $dbh);
} else { # child.
&DEBUG("b4 delfork 1");
&shutdown() if (defined $shm and defined $dbh);
} else { # child.
&DEBUG("b4 delfork 1");
- &delForked($modulebase);
+ &delForked($modulename);
&ERROR("cannot load my module: $modulebase");
if ($bot_pid != $$) { # child.
&DEBUG("b4 delfork 2");
&ERROR("cannot load my module: $modulebase");
if ($bot_pid != $$) { # child.
&DEBUG("b4 delfork 2");
- &delForked($modulebase);
+ &delForked($modulename);