[Jifty-commit] r2663 - jifty/trunk/lib/Jifty

jifty-commit at lists.jifty.org jifty-commit at lists.jifty.org
Sat Jan 27 06:48:58 EST 2007


Author: ruz
Date: Sat Jan 27 06:48:54 2007
New Revision: 2663

Modified:
   jifty/trunk/lib/Jifty/JSON.pm

Log:
* enable UTF-8 flag awarness in JSON libraries to fix problem in validation
  of values during creating a record via the admin interface when column has
  valid values with unicode chars.

Modified: jifty/trunk/lib/Jifty/JSON.pm
==============================================================================
--- jifty/trunk/lib/Jifty/JSON.pm	(original)
+++ jifty/trunk/lib/Jifty/JSON.pm	Sat Jan 27 06:48:54 2007
@@ -19,7 +19,7 @@
 single-quoted string output.
 
 If the faster L<JSON::Syck> is available, it is preferred over the pure-perl
-L<JSON>, as it provides native support for single-quoted strings..
+L<JSON>, as it provides native support for single-quoted strings.
 
 =head1 METHODS
 
@@ -32,11 +32,13 @@
     if (eval { require JSON::Syck; JSON::Syck->VERSION(0.05) }) {
         *jsonToObj = *_jsonToObj_syck;
         *objToJson = *_objToJson_syck;
+        $JSON::Syck::ImplicitUnicode = 1;
     }
     else {
         require JSON;
         *jsonToObj = *_jsonToObj_pp;
         *objToJson = *_objToJson_pp;
+        $JSON::UTF8 = 1;
     }
 }
 


More information about the Jifty-commit mailing list