Skip to content

Commit

Permalink
Filter out values that are None. See #9
Browse files Browse the repository at this point in the history
  • Loading branch information
Svedrin authored Aug 1, 2023
1 parent 105a868 commit 9c8bcb5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mqtt_pushgateway.py
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ def _flatten(into_result, prefix, val):
elif isinstance(val, list):
for idx, elem in enumerate(val):
_flatten(into_result, prefix + [str(idx)], elem)
else:
elif val is not None:
into_result["/".join(prefix)] = val
return into_result

Expand Down

0 comments on commit 9c8bcb5

Please sign in to comment.