Subject: | forkit function is broken |
The forkit function doesn't seem print data to the channel.
Subject: | forky.pl |
package SayForkTest;
use strict;
use warnings;
use base qw(Bot::BasicBot);
my $b=SayForkTest->new(
server=>'localhost',
port=>1234,
nick=>'Test',
channels=>'#test'
);
$b->run();
sub connected {
my $self=shift;
print "We're in the connected sub!\n";
$self->forkit(run=>\&to_fork, arguments=>['arg1', 'arg2']);
}
sub to_fork {
my $self=shift;
foreach (@_){ print $_."\n"; }
return 'Returned from to_fork!';
}