X-Git-Url: https://sipb.mit.edu/gitweb.cgi/ikiwiki.git/blobdiff_plain/3922ba15ba04d5519e77eae3cdc760e5853687d4..279db7860dc98bedbd8333bb7de57251dcfb223d:/IkiWiki/Plugin/edittemplate.pm diff --git a/IkiWiki/Plugin/edittemplate.pm b/IkiWiki/Plugin/edittemplate.pm index aa72b0845..b7651ce02 100644 --- a/IkiWiki/Plugin/edittemplate.pm +++ b/IkiWiki/Plugin/edittemplate.pm @@ -21,7 +21,8 @@ sub needsbuild (@) { #{{{ foreach my $page (keys %pagestate) { if (exists $pagestate{$page}{edittemplate}) { - if (grep { $_ eq $pagesources{$page} } @$needsbuild) { + if (exists $pagesources{$page} && + grep { $_ eq $pagesources{$page} } @$needsbuild) { # remove state, it will be re-added # if the preprocessor directive is still # there during the rebuild