X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=lib%2FWeb%2FDispatch%2FParamParser.pm;fp=lib%2FWeb%2FDispatch%2FParamParser.pm;h=3caf160a84895a4e54e7c8524b940f4d15246e9c;hb=c62cf40ac80b302b71683630b11b6157f018ba4a;hp=0f403aa17961d30b334a6c2467ca7909f38880ed;hpb=6b9d4bcdf300d1f3dea31532214089e4701f4b96;p=catagits%2FWeb-Simple.git diff --git a/lib/Web/Dispatch/ParamParser.pm b/lib/Web/Dispatch/ParamParser.pm index 0f403aa..3caf160 100644 --- a/lib/Web/Dispatch/ParamParser.pm +++ b/lib/Web/Dispatch/ParamParser.pm @@ -27,7 +27,8 @@ sub get_unpacked_body_from { _unpack_params($buf); } elsif (index($ct, 'multipart/form-data') >= 0) { my $p = get_unpacked_body_object_from($_[0])->param; - # forcible arrayification + # forcible arrayification (functional, $p does not belong to us, + # do NOT replace this with a side-effect ridden "simpler" version) +{ map +(ref($p->{$_}) eq 'ARRAY' ? ($_ => $p->{$_})