Skip to content

Commit

Permalink
Merge pull request #6155 from Automattic/fix/avoid-mb-encoding-bugs-i…
Browse files Browse the repository at this point in the history
…n-sync

Switch to wp_json_encode to gracefully handle encoding issues
  • Loading branch information
gravityrail authored Jan 24, 2017
2 parents a1681d9 + 1a3a3f9 commit 0493b26
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sync/class.jetpack-sync-json-deflate-array-codec.php
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public function decode( $input ) {

// @see https://gist.github.com/muhqu/820694
private function json_serialize( $any ) {
return json_encode( $this->json_wrap( $any ) );
return wp_json_encode( $this->json_wrap( $any ) );
}

private function json_unserialize( $str ) {
Expand Down

0 comments on commit 0493b26

Please sign in to comment.