Skip to content

Commit

Permalink
Merge pull request #125 from liggett2820/json_extension_bug_fix
Browse files Browse the repository at this point in the history
BUG: Json extension bug fix
  • Loading branch information
ZLLentz authored Aug 3, 2022
2 parents a7c875f + c8377c6 commit 9890403
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions atef/widgets/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,8 @@ def save_as(self, *args, filename: Optional[str] = None, **kwargs):
caption='Save as',
filter='Json Files (*.json)',
)
if not filename.endswith('.json'):
filename += '.json'
try:
with open(filename, 'w') as fd:
json.dump(serialized, fd, indent=2)
Expand Down

0 comments on commit 9890403

Please sign in to comment.