From f5b1154e704d97b63edf6fc9e699ca114c8603ba Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 20 Apr 2017 13:42:02 -0300 Subject: [PATCH] Bug 14224: Use encode_json instead of to_json To handle unicode characters properly Signed-off-by: Kyle M Hall --- opac/svc/patron_notes | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/opac/svc/patron_notes b/opac/svc/patron_notes index e26c266f7c..d241f0c970 100755 --- a/opac/svc/patron_notes +++ b/opac/svc/patron_notes @@ -19,7 +19,7 @@ use Modern::Perl; -use JSON qw( to_json ); +use JSON qw( encode_json ); use C4::Service; use C4::Auth qw /check_cookie_auth/; use C4::Letters; @@ -97,7 +97,7 @@ if ($is_ajax) { $status = "fail"; } - my $json = to_json ( { status => $status, note => $clean_note, issue_id => $issue_id } ); + my $json = encode_json ( { status => $status, note => $clean_note, issue_id => $issue_id } ); output_with_http_headers($query, undef, $json, 'json'); exit; } # END Issue Note -- 2.39.2