Skip to content

Commit

Permalink
Fixes bug in Result unserialization
Browse files Browse the repository at this point in the history
Signed-off-by: Lorenzo Addazi <[email protected]>
  • Loading branch information
loradd committed Nov 20, 2023
1 parent 29c432c commit 5387ae8
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions pylasu/astruntime.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,9 @@


def unserialize_result(json_result, root_unserializer) -> Result:
return Result(
root=root_unserializer(json_result['root']) if 'root' in json_result else None,
issues=[unserialize_issue(issue) for issue in json_result['issues']] if 'issues' in json_result else []
)
result = Result(root=root_unserializer(json_result['root']) if 'root' in json_result else None)
result.issues = [unserialize_issue(issue) for issue in json_result['issues']] if 'issues' in json_result else []
return result


def unserialize_issue(json_issue) -> Issue:
Expand Down

0 comments on commit 5387ae8

Please sign in to comment.