mirror of
https://github.com/pragma-/pbot.git
synced 2024-12-24 11:42:35 +01:00
Interpreter: minor formatting clean-up
This commit is contained in:
parent
da43217d3e
commit
bd04feda81
@ -267,8 +267,12 @@ sub interpret {
|
||||
$arguments =~ s/\s*(?<!\\)\|\s*{(\Q$pipe\E)}.*$//s;
|
||||
$pipe =~ s/^\s+|\s+$//g;
|
||||
|
||||
if (exists $context->{pipe}) { $context->{pipe_rest} = "$rest | { $context->{pipe} }$context->{pipe_rest}"; }
|
||||
else { $context->{pipe_rest} = $rest; }
|
||||
if (exists $context->{pipe}) {
|
||||
$context->{pipe_rest} = "$rest | { $context->{pipe} }$context->{pipe_rest}";
|
||||
} else {
|
||||
$context->{pipe_rest} = $rest;
|
||||
}
|
||||
|
||||
$context->{pipe} = $pipe;
|
||||
}
|
||||
|
||||
@ -793,7 +797,7 @@ sub handle_result {
|
||||
if ($result =~ s#^(/say|/me) ##) { $context->{prepend} = $1; }
|
||||
elsif ($result =~ s#^(/msg \S+) ##) { $context->{prepend} = $1; }
|
||||
|
||||
if ($context->{pipe}) {
|
||||
if (exists $context->{pipe}) {
|
||||
my ($pipe, $pipe_rest) = (delete $context->{pipe}, delete $context->{pipe_rest});
|
||||
if (not $context->{alldone}) {
|
||||
$context->{command} = "$pipe $result $pipe_rest";
|
||||
|
Loading…
Reference in New Issue
Block a user