$log_open=1;
}
eval {
- Sys::Syslog::syslog($type, "%s", join(" ", @_));
+ Sys::Syslog::syslog($type, "[$config{wikiname}] %s", join(" ", @_));
};
}
elsif (! $config{cgi}) {
package IkiWiki::FailReason;
-use overload (
- '""' => sub { return ${$_[0]} },
- '0+' => sub { return 0 },
+use overload ( #{{{
+ '""' => sub { ${$_[0]} },
+ '0+' => sub { 0 },
'!' => sub { bless $_[0], 'IkiWiki::SuccessReason'},
fallback => 1,
-);
+); #}}}
-sub new {
+sub new { #{{{
bless \$_[1], $_[0];
-}
+} #}}}
package IkiWiki::SuccessReason;
-use overload (
- '""' => sub { return ${$_[0]} },
- '0+' => sub { return 1 },
+use overload ( #{{{
+ '""' => sub { ${$_[0]} },
+ '0+' => sub { 1 },
'!' => sub { bless $_[0], 'IkiWiki::FailReason'},
fallback => 1,
-);
+); #}}}
-sub new {
+sub new { #{{{
bless \$_[1], $_[0];
-}
+}; #}}}
package IkiWiki::PageSpec;