Skip to content

Commit

Permalink
BUG: to unescape JSON string, do not use str() but .encode('utf-8') i…
Browse files Browse the repository at this point in the history
…nstead
  • Loading branch information
Petr Panuska committed Jan 6, 2021
1 parent 18a1dba commit c5bb827
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ operation:
import json, sys
try:
if escape == 'false': #unescape
output_string = str(json.loads(input_string))
output_string = json.loads(input_string).encode('utf-8')
else: #escape
output_string = json.dumps(input_string)
failure = ''
Expand Down

0 comments on commit c5bb827

Please sign in to comment.