From 6a0af02d3f30103196b9452077b5a68177c9fde4 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sat, 9 Jan 2010 16:07:01 -0500 Subject: make decode_form_utf8 safe for arrays --- IkiWiki/CGI.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'IkiWiki') diff --git a/IkiWiki/CGI.pm b/IkiWiki/CGI.pm index 866711a71..cd4a5574c 100644 --- a/IkiWiki/CGI.pm +++ b/IkiWiki/CGI.pm @@ -65,8 +65,9 @@ sub decode_form_utf8 ($) { if ($] >= 5.01) { my $form = shift; foreach my $f ($form->field) { + my @value=map { decode_utf8($_) } $form->field($f); $form->field(name => $f, - value => decode_utf8($form->field($f)), + value => \@value, force => 1, ); } -- cgit v1.2.3