bitpiston / oyster

A Perl web application framework.
Other
3 stars 1 forks source link

join( ... map { ... } ... ) failing under FastCGI but not server.pl #49

Open einkoro opened 11 years ago

einkoro commented 11 years ago

Same version of Perl at that.

Works under server.pl and fails under FastCGI:

my $dyn_name = join('-', map { s!\.xsl$!!og; s!/!_!og } @stylesheets) . '.xsl';

Works under both but isn't as nice – plus the other one used to work:

my $dyn_name;
for my $file (@stylesheets) {
    $dyn_name = $file;
    $dyn_name =~ s/\.xsl$//og;
    $dyn_name =~ s/\//_/og;
    $dyn_name .= '.xsl';
}