hMatoba / Piexif

Exif manipulation with pure python script.
MIT License
367 stars 81 forks source link

UnboundLocalError: local variable 'file_type' referenced before assignment #125

Closed CharlesShine closed 8 months ago

CharlesShine commented 2 years ago

Rencently,use pip install Piexif, Report the above error,the error file path is 'xxxx/python3.x/site-packages/piexif/_removel.py'。I found problem with the local variables ('file_type' and 'new_data' ) in the function。

method: Add file_type="" new_data=b""
in the first line of the function

Hope it helps others