Created
June 7, 2012 07:28
-
-
Save ywjno/2887170 to your computer and use it in GitHub Desktop.
doesn't escape when used to_json method
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
something.to_json.gsub(/\\u([0-9a-z]{4})/){|s| [$1.to_i(16)].pack("U")} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment