Skip to content

Commit

Permalink
Merge pull request #327 from mdk-man/master
Browse files Browse the repository at this point in the history
handle meta update when key is present but its value is None
  • Loading branch information
EvanBldy authored Jul 30, 2024
2 parents 96981e2 + 36afb47 commit 752096c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion gazu/shot.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,8 @@ def update_shot_data(shot, data={}, client=default):
"""
shot = normalize_model_parameter(shot)
current_shot = get_shot(shot["id"], client=client)
updated_shot = {"id": current_shot["id"], "data": current_shot["data"]}
current_data = current_shot["data"] if current_shot["data"] is not None else {}
updated_shot = {"id": current_shot["id"], "data": current_data}
updated_shot["data"].update(data)
return update_shot(updated_shot, client=client)

Expand Down

0 comments on commit 752096c

Please sign in to comment.