We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7524370 commit 7b79edbCopy full SHA for 7b79edb
1 file changed
src/wids/wids_decode.py
@@ -168,9 +168,9 @@ def default_decoder(
168
decode_all_gz(result, update_key=gz_update_key) # for backwards compatibility
169
decode_basic(result)
170
171
- if format.lower() == "pil":
+ if isinstance(format, str) and format.lower() == "pil":
172
decode_images_to_pil(result)
173
- elif format.lower() == "numpy":
+ elif isinstance(format, str) and format.lower() == "numpy":
174
decode_images_to_numpy(result)
175
else:
176
raise ValueError(f"Unknown format: {format}")
0 commit comments