Skip to content

Commit

Permalink
Mistake where the fetched id was not used
Browse files Browse the repository at this point in the history
  • Loading branch information
alneberg committed Nov 1, 2021
1 parent 6e43e30 commit 0435deb
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions sensorpush_to_statusdb.py
Original file line number Diff line number Diff line change
Expand Up @@ -458,10 +458,9 @@ def main(

sd_dict = sd.format_for_statusdb()

existing_id = None
if view_call.rows:
sd_dict = SensorDocument.merge_with(sd_dict, view_call.rows[0].value)
sd_dict["id"] = existing_id
sd_dict["id"] = view_call.rows[0].value["id"]

if push:
logging.info(f'Saving {sd_dict["sensor_name"]} to statusdb')
Expand Down

0 comments on commit 0435deb

Please sign in to comment.