From 996e450bee675aa20a843a23f4fd229123e2100e Mon Sep 17 00:00:00 2001 From: Ailin Nemui Date: Fri, 29 Jan 2016 08:59:40 -0300 Subject: aspell_complete: Fix crash when the dictionary is unset This will be fixed on the irssi side too. --- scripts/aspell_complete.pl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts') diff --git a/scripts/aspell_complete.pl b/scripts/aspell_complete.pl index da8d08c..93b2145 100644 --- a/scripts/aspell_complete.pl +++ b/scripts/aspell_complete.pl @@ -18,7 +18,7 @@ use vars qw($VERSION %IRSSI); use Irssi; use Text::Aspell; -$VERSION = '1.00'; +$VERSION = '1.01'; %IRSSI = ( authors => 'Philipp Haegi', contact => 'phaegi\@mimir.ch', @@ -59,7 +59,7 @@ sub rotate_dict() { Irssi::signal_add_last 'complete word' => sub { my ($complist, $window, $word, $linestart, $want_space) = @_; - push(@$complist, $speller->suggest( $word )); + push(@$complist, grep { defined } $speller->suggest( $word )); # eliminate null pointers }; -- cgit v1.2.3