summaryrefslogtreecommitdiff
path: root/scripts/privmsg.pl
diff options
context:
space:
mode:
authorTimo Sirainen <cras@irssi.org>2001-07-16 20:22:45 +0000
committercras <cras@dbcabf3a-b0e7-0310-adc4-f8d773084564>2001-07-16 20:22:45 +0000
commit69a6096b8b4e0b94e3ba327801a120be2d446636 (patch)
treedd31da39c6a23514d8ade048fdef3426bfa4096f /scripts/privmsg.pl
parent0d3b5c729f16a0c8c2d7ccbc04854de2e8b5b45a (diff)
downloadirssi-69a6096b8b4e0b94e3ba327801a120be2d446636.zip
added "use strict" for all scripts, made some small changes.
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@1639 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'scripts/privmsg.pl')
-rw-r--r--scripts/privmsg.pl3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/privmsg.pl b/scripts/privmsg.pl
index c667220c..b1d119cb 100644
--- a/scripts/privmsg.pl
+++ b/scripts/privmsg.pl
@@ -1,6 +1,7 @@
# listen PRIVMSGs - send a notice to yourself when your nick is meantioned
use Irssi;
+use strict;
sub event_privmsg {
my ($server, $data, $nick, $address) = @_;
@@ -8,7 +9,7 @@ sub event_privmsg {
return if (!$server->ischannel($target));
- $mynick = $server->{nick};
+ my $mynick = $server->{nick};
return if ($text !~ /\b$mynick\b/);
$server->command("/notice $mynick In channel $target, $nick!$address said: $text");