Skip to content

Commit

Permalink
fix: josn type instead of str
Browse files Browse the repository at this point in the history
  • Loading branch information
iw4p committed Dec 1, 2023
1 parent b9e5d91 commit 8bbb2d2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion partialjson/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"""
from .json_parser import JSONParser

__version__ = "0.0.3"
__version__ = "0.0.4"
__author__ = 'Nima Akbarzadeh'
__author_email__ = "[email protected]"
__license__ = "MIT"
Expand Down
4 changes: 2 additions & 2 deletions partialjson/json_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@ def parse(self, s):
self.last_parse_reminding = reminding
if self.on_extra_token and reminding:
self.on_extra_token(s, data, reminding)
return json.dumps(data)
return json.loads(json.dumps(data))
else:
return json.dumps({})
return json.loads({})

def parse_any(self, s, e):
if not s:
Expand Down

0 comments on commit 8bbb2d2

Please sign in to comment.