mirror of
https://github.com/beetbox/beets.git
synced 2026-01-09 09:22:55 +01:00
Add more error handling for the img.save function
This commit is contained in:
parent
9c3f4a4ac8
commit
99ca3e96d4
1 changed files with 5 additions and 1 deletions
|
|
@ -124,7 +124,11 @@ class EmbedCoverArtPlugin(BeetsPlugin):
|
|||
self._log.error("Error: {}".format(e))
|
||||
return
|
||||
if img.format:
|
||||
img.save('temp.png', format='PNG')
|
||||
try:
|
||||
img.save('temp.png', format='PNG')
|
||||
except IOError as e:
|
||||
self._log.error("Cannot save image: {}".format(e))
|
||||
return
|
||||
tempimg = 'temp.png'
|
||||
items = lib.items(decargs(args))
|
||||
# Confirm with user.
|
||||
|
|
|
|||
Loading…
Reference in a new issue