X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/07bb08d0944a0282d6ed332deeefe347bc88139c..88b080f8a40840c62abd76fbf0330cb580713f1f:/IkiWiki/Setup.pm?ds=sidebyside diff --git a/IkiWiki/Setup.pm b/IkiWiki/Setup.pm index 2cf01ea68..2b0259e2a 100644 --- a/IkiWiki/Setup.pm +++ b/IkiWiki/Setup.pm @@ -28,11 +28,12 @@ sub load ($;$) { } close IN; - if ($content=~/(use\s+)?IkiWiki::Setup::(\w+)/) { + if ($content=~/((?:use|require)\s+)?IkiWiki::Setup::(\w+)/) { $config{setuptype}=$2; if ($1) { error sprintf(gettext("cannot load %s in safe mode"), $file) if $safemode; + no warnings; eval IkiWiki::possibly_foolish_untaint($content); error("$file: ".$@) if $@; } @@ -122,7 +123,7 @@ sub getsetup () { # Load all plugins, so that all setup options are available. my @plugins=IkiWiki::listplugins(); foreach my $plugin (@plugins) { - eval { IkiWiki::loadplugin($plugin) }; + eval { IkiWiki::loadplugin($plugin, 1) }; if (exists $IkiWiki::hooks{checkconfig}{$plugin}{call}) { my @s=eval { $IkiWiki::hooks{checkconfig}{$plugin}{call}->() }; }