diff options
author | Jesse Luehrs <doy@tozt.net> | 2013-06-08 12:06:49 -0500 |
---|---|---|
committer | Jesse Luehrs <doy@tozt.net> | 2013-06-08 12:06:49 -0500 |
commit | dc7244fa1625a30fde2641b1d86ca42e87852866 (patch) | |
tree | a07c93dce8e0d0bc11422a3330a46af68b645926 /lib/Reply/Plugin/Nopaste.pm | |
parent | f4775be782ef0cd1003190169b539b3ba2367292 (diff) | |
download | reply-dc7244fa1625a30fde2641b1d86ca42e87852866.tar.gz reply-dc7244fa1625a30fde2641b1d86ca42e87852866.zip |
make sure plugins can handle not going through read_line
Diffstat (limited to 'lib/Reply/Plugin/Nopaste.pm')
-rw-r--r-- | lib/Reply/Plugin/Nopaste.pm | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/Reply/Plugin/Nopaste.pm b/lib/Reply/Plugin/Nopaste.pm index 566c668..7265dc9 100644 --- a/lib/Reply/Plugin/Nopaste.pm +++ b/lib/Reply/Plugin/Nopaste.pm @@ -76,7 +76,10 @@ sub loop { my $line = delete $self->{line}; my $result = delete $self->{result}; - $self->{history} .= "$prompt$line$result"; + $self->{history} .= "$prompt$line$result" + if defined $prompt + && defined $line + && defined $result; $continue; } |