From: Don Armstrong Date: Fri, 4 Jan 2008 00:06:27 +0000 (+0000) Subject: * print sometimes returns false, so stop using and to join them X-Git-Url: https://git.donarmstrong.com/?p=irc.git;a=commitdiff_plain;h=6a39d108770b9810df707c6ec778156cd9458dc0 * print sometimes returns false, so stop using and to join them --- diff --git a/.irssi/scripts/auto_bleh.pl b/.irssi/scripts/auto_bleh.pl index 1ea3a1c..605cb68 100644 --- a/.irssi/scripts/auto_bleh.pl +++ b/.irssi/scripts/auto_bleh.pl @@ -324,11 +324,17 @@ sub attempt_actions { Irssi::print(i_want($actions->{$_})) if $DEBUG; # Find the server to take action on my $server = Irssi::server_find_chatnet($actions->{$_}->{network}); - Irssi::print("Unable to find server for chatnet: $actions->{$_}->{network}") and return if not defined $server; + if (not defined $server) { + Irssi::print("Unable to find server for chatnet: $actions->{$_}->{network}"); + return; + } Irssi::print("Found server for chatnet: $actions->{$_}->{network}") if $DEBUG; # Find the channel to take action on my $s_channel = $server->channel_find($actions->{$_}->{channel}); - Irssi::print("Unable to find channel for channel: $actions->{$_}->{channel}") and return if not defined $s_channel; + if (not defined $s_channel){ + Irssi::print("Unable to find channel for channel: $actions->{$_}->{channel}"); + return; + } Irssi::print("Found channel for channel: $actions->{$_}->{channel}") if $DEBUG; # Are we opped on that channel? if ($s_channel->{chanop}) { # Yes? Take the action against the user.