Skip to content

Commit

Permalink
More explicit custom_fill_val check to allow 0 values
Browse files Browse the repository at this point in the history
  • Loading branch information
blimlim committed Sep 27, 2024
1 parent 239a69e commit f3fbd44
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion umpost/um2netcdf.py
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ def fix_fill_value(cube, custom_fill_val=None):
custom_fill_val: Optional custom fill value. Type should match
the cube data's type.
"""
if custom_fill_val:
if custom_fill_val is not None:
if type(custom_fill_val) == cube.data.dtype:
fill_value = custom_fill_val
else:
Expand Down

0 comments on commit f3fbd44

Please sign in to comment.