From: Joey Hess Date: Wed, 31 Dec 2008 05:08:46 +0000 (-0500) Subject: make sure value is defined before using it as an array X-Git-Tag: 3.00~4^2~1 X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/commitdiff_plain/0daa4eb521a32b9ed00e99a2155416a312d478de make sure value is defined before using it as an array --- diff --git a/IkiWiki/Plugin/websetup.pm b/IkiWiki/Plugin/websetup.pm index a47c29976..2d978c5b4 100644 --- a/IkiWiki/Plugin/websetup.pm +++ b/IkiWiki/Plugin/websetup.pm @@ -138,7 +138,8 @@ sub showfields ($$$@) { my $value=$config{$key}; - if ($info{safe} && (ref $value eq 'ARRAY' || ref $info{example} eq 'ARRAY')) { + if ($info{safe} && defined $value && + (ref $value eq 'ARRAY' || ref $info{example} eq 'ARRAY')) { $value=[@{$value}, "", ""]; # blank items for expansion }