Call CGI->param_fetch instead of CGI->param in array context
[ikiwiki.git] / IkiWiki / CGI.pm
index 0224c2aac34d442c47b04e80d13a06db083fa8e2..f448db6ef8a213fa84d57f72ad236569c510d304 100644 (file)
@@ -122,7 +122,8 @@ sub decode_cgi_utf8 ($) {
        if ($] < 5.01) {
                my $cgi = shift;
                foreach my $f ($cgi->param) {
-                       $cgi->param($f, map { decode_utf8 $_ } $cgi->param($f));
+                       $cgi->param($f, map { decode_utf8 $_ }
+                               @{$cgi->param_fetch($f)});
                }
        }
 }