From: Barijaona Ramaholimihaso Date: Sat, 22 Sep 2007 06:03:45 +0000 (+0000) Subject: Avoid "conditional and" for preparing file list in static rendering X-Git-Tag: debian/2.1.2-2~98 X-Git-Url: https://git.deb.at/w?a=commitdiff_plain;h=2f585f8b41e5414917fd5b76c557e80474f6e4f2;p=pkg%2Fblosxom.git Avoid "conditional and" for preparing file list in static rendering --- diff --git a/blosxom.cgi b/blosxom.cgi index b80cfbc..f2861db 100755 --- a/blosxom.cgi +++ b/blosxom.cgi @@ -324,8 +324,8 @@ if (!$ENV{GATEWAY_INTERFACE} and param('-password') and $static_password and par foreach ( ('', split /\//, $path) ) { $p .= "/$_"; $p =~ s!^/!!; - $done{$p}++ and next; - (-d "$static_dir/$p" or $p =~ /\.$file_extension$/) or mkdir "$static_dir/$p", 0755; + next if $done{$p}++; + mkdir "$static_dir/$p", 0755 unless (-d "$static_dir/$p" or $p =~ /\.$file_extension$/); foreach $flavour ( @static_flavours ) { my $content_type = (&$template($p,'content_type',$flavour)); $content_type =~ s!\n.*!!s;