From ef6eabfa9e425581ab8e6316e732ca4e83cf436c Mon Sep 17 00:00:00 2001 From: Colin Kuskie Date: Wed, 12 Sep 2012 09:20:27 -0700 Subject: [PATCH] Handle UTF-8 characters in asset titles in the trash. Fixes bug #12385. --- docs/changelog/7.x.x.txt | 1 + lib/WebGUI/AssetTrash.pm | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/changelog/7.x.x.txt b/docs/changelog/7.x.x.txt index f35040e94..5628f3315 100644 --- a/docs/changelog/7.x.x.txt +++ b/docs/changelog/7.x.x.txt @@ -5,6 +5,7 @@ - fixed #12339: Upgrade to 7.10 causes metadata values to "disappear" (Dale Trexel) - Upgraded TinyMCE to 3.5.6 - fixed #12362: Thingy default Y/N field overly default + - fixed #12385: UTF-8 characters in Asset title break the Trash 7.10.26 - fixed: Template diagnostics when called without a session asset. diff --git a/lib/WebGUI/AssetTrash.pm b/lib/WebGUI/AssetTrash.pm index 23eaa7f34..ff51ec5f9 100644 --- a/lib/WebGUI/AssetTrash.pm +++ b/lib/WebGUI/AssetTrash.pm @@ -520,7 +520,7 @@ sub www_manageTrash { \n"; # To avoid string escaping issues - my $json = JSON->new; + my $json = JSON->new->utf8(1); my $amethod = sub { my ($method, @args) = @_; my $array = $json->encode(\@args);