Avoid "conditional and" for setting the %f entries hash
authorBarijaona Ramaholimihaso <barijaona@users.sourceforge.net>
Sat, 22 Sep 2007 09:02:49 +0000 (09:02 +0000)
committerBarijaona Ramaholimihaso <barijaona@users.sourceforge.net>
Sat, 22 Sep 2007 09:02:49 +0000 (09:02 +0000)
blosxom.cgi

index f4666d0..2875b44 100755 (executable)
@@ -453,7 +453,7 @@ sub generate {
 
     if ( $currentdir =~ /(.*?)([^\/]+)\.(.+)$/ and $2 ne 'index' ) {
       $currentdir = "$1$2.$file_extension";
-      $files{"$datadir/$1$2.$file_extension"} and %f = ( "$datadir/$1$2.$file_extension" => $files{"$datadir/$1$2.$file_extension"} );
+      %f = ( "$datadir/$currentdir" => $files{"$datadir/$currentdir"} ) if $files{"$datadir/$currentdir"};
     } 
     else { 
       $currentdir =~ s!/index\..+$!!;