summaryrefslogtreecommitdiff
path: root/IkiWiki.pm
diff options
context:
space:
mode:
authorJoey Hess <joey@gnu.kitenet.net>2009-03-27 15:09:41 -0400
committerJoey Hess <joey@gnu.kitenet.net>2009-03-27 15:09:41 -0400
commit825e2b1378b1def4980e36642ed84999599eb017 (patch)
tree8c5225715c9cf7a3405dbc679f124f74ca9983e7 /IkiWiki.pm
parentf4a1732b0e65ea4459098e4e852dff10a5af9320 (diff)
parentc8237b4351f6023b3d3a661df2568c6d7488b8cf (diff)
Merge branch 'master' into po
Conflicts: debian/control
Diffstat (limited to 'IkiWiki.pm')
-rw-r--r--IkiWiki.pm8
1 files changed, 5 insertions, 3 deletions
diff --git a/IkiWiki.pm b/IkiWiki.pm
index 2640f85a2..63da5d0dd 100644
--- a/IkiWiki.pm
+++ b/IkiWiki.pm
@@ -533,7 +533,7 @@ sub loadplugins () {
run_hooks(getopt => sub { shift->() });
if (grep /^-/, @ARGV) {
- print STDERR "Unknown option: $_\n"
+ print STDERR "Unknown option (or missing parameter): $_\n"
foreach grep /^-/, @ARGV;
usage();
}
@@ -639,8 +639,10 @@ sub pagetype ($) {
if ($file =~ /\.([^.]+)$/) {
return $1 if exists $hooks{htmlize}{$1};
}
- elsif ($hooks{htmlize}{basename($file)}{noextension}) {
- return basename($file);
+ my $base=basename($file);
+ if (exists $hooks{htmlize}{$base} &&
+ $hooks{htmlize}{$base}{noextension}) {
+ return $base;
}
return;
}