summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatarDoug Freed <dwfreed@mtu.edu>2015-04-16 07:54:57 +0400
committerLibravatarDoug Freed <dwfreed@mtu.edu>2015-04-16 07:56:53 +0400
commit444401d899ee674e1c1672347fdb65a9d24f1999 (patch)
tree9aa239b7aae5c820eabb4c72496aafc03076695b
parent77ac451eacee0e5757c5ef74591fca38984a0b07 (diff)
Fix whoGotHit to anchor properly
-rw-r--r--modules/event.pl4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/event.pl b/modules/event.pl
index 79441f5..65c8674 100644
--- a/modules/event.pl
+++ b/modules/event.pl
@@ -613,7 +613,7 @@ sub whoGotHit
my $regex = $cvt->convert($div[0]);
foreach my $nick (keys %::sn) {
next unless defined($::sn{$nick}{user});
- if (lc ($nick.'!'.$::sn{$nick}{user}.'@'.$::sn{$nick}{host}) =~ lc $regex) {
+ if (lc ($nick.'!'.$::sn{$nick}{user}.'@'.$::sn{$nick}{host}) =~ /^$regex$/i) {
push @affected, $nick if defined($::sc{$chan}{users}{$nick});
}
}
@@ -622,7 +622,7 @@ sub whoGotHit
my $regex = $cvt->convert($div[0]);
foreach my $nick (keys %::sn) {
next unless defined($::sn{$nick}{account});
- if (lc ($::sn{$nick}{account}) =~ lc $regex) {
+ if (lc ($::sn{$nick}{account}) =~ /^$regex$/i) {
push @affected, $nick if defined($::sc{$chan}{users}{$nick});
}
}