X-Git-Url: http://git.vpit.fr/?a=blobdiff_plain;f=Xchat%2FXPI%2FEvents.pm;h=d851caaeb961d04e705cd3753527ff4d627cd006;hb=ffce0ac1da463a72159ea12236e1be85d9361383;hp=3bb797ffd1930287f46b0c9b696449dc2ce9984b;hpb=6233c622e5c4cceefc8ed019b5a9355a690f2050;p=perl%2Fscripts%2Fxchat.git diff --git a/Xchat/XPI/Events.pm b/Xchat/XPI/Events.pm index 3bb797f..d851caa 100644 --- a/Xchat/XPI/Events.pm +++ b/Xchat/XPI/Events.pm @@ -5,9 +5,6 @@ use warnings; use Xchat qw<:all>; -use lib get_info 'xchatdir'; -use Xchat::XPI; - use constant DEFAULT_DELAY => 1000; our $VERSION = '0.04'; @@ -21,7 +18,7 @@ sub _delay_cb { } sub delay { - my $delay = $_[0]; + my $delay = shift; if (defined $delay) { $delay = int $delay; @@ -45,7 +42,9 @@ sub _filter_cb { } sub filter { - hook_print $_[0], \&_filter_cb, { data => \@_ }; + my $from = shift; + + hook_print $from, \&_filter_cb, { data => \@_ }; } use base qw;