mirror of
https://github.com/pragma-/pbot.git
synced 2024-11-02 18:19:33 +01:00
Interpreter: minor clean-up
This commit is contained in:
parent
50d4a2a94d
commit
a9eb7cc24b
@ -553,6 +553,9 @@ sub handle_result {
|
||||
# if passed, allow $result parameter to override contextual result
|
||||
$result //= $context->{result};
|
||||
|
||||
# ensure we have a command result to work with
|
||||
$result //= '';
|
||||
|
||||
# preservation of consecutive whitespace is disabled by default
|
||||
$context->{preserve_whitespace} //= 0;
|
||||
|
||||
@ -564,11 +567,6 @@ sub handle_result {
|
||||
$self->{pbot}->{logger}->log(Dumper $context);
|
||||
}
|
||||
|
||||
# ensure we have a command result to work with
|
||||
if (not defined $result or length $result == 0) {
|
||||
$result = "";
|
||||
}
|
||||
|
||||
# strip and store /command prefixes
|
||||
# to be re-added after result processing
|
||||
if ($result =~ s!^(/say|/me|/msg \S+) !!) {
|
||||
|
@ -25,7 +25,7 @@ use PBot::Imports;
|
||||
# These are set by the /misc/update_version script
|
||||
use constant {
|
||||
BUILD_NAME => "PBot",
|
||||
BUILD_REVISION => 4363,
|
||||
BUILD_REVISION => 4364,
|
||||
BUILD_DATE => "2021-08-23",
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user