We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents b6514dd + 074f937 commit 7465c1bCopy full SHA for 7465c1b
jsonpatch.py
@@ -98,7 +98,7 @@ def multidict(ordered_pairs):
98
99
# The "object_pairs_hook" parameter is used to handle duplicate keys when
100
# loading a JSON object.
101
-json.load = functools.partial(json.load, object_pairs_hook=multidict)
+_jsonloads = functools.partial(json.loads, object_pairs_hook=multidict)
102
103
104
def apply_patch(doc, patch, in_place=False):
@@ -260,7 +260,7 @@ def from_string(cls, patch_str):
260
261
:return: :class:`JsonPatch` instance.
262
"""
263
- patch = json.loads(patch_str)
+ patch = _jsonloads(patch_str)
264
return cls(patch)
265
266
@classmethod
0 commit comments