diff --git a/beets/art.py b/beets/art.py index 8b77899fbc..79bdfefe42 100644 --- a/beets/art.py +++ b/beets/art.py @@ -25,7 +25,6 @@ from beets.util import displayable_path, syspath from beets.util.artresizer import ArtResizer from beets import mediafile -from beets import config def mediafile_image(image_path, maxwidth=None): @@ -191,17 +190,8 @@ def extract_first(log, outpath, items): def clear(log, lib, query): - id3v23 = config['id3v23'].get(bool) - items = lib.items(query) log.info(u'Clearing album art from {0} items', len(items)) for item in items: log.debug(u'Clearing art for {0}', item) - try: - mf = mediafile.MediaFile(syspath(item.path), id3v23) - except mediafile.UnreadableFileError as exc: - log.warning(u'Could not read file {0}: {1}', - displayable_path(item.path), exc) - else: - del mf.art - mf.save() + item.try_write(tags={'images': None}) diff --git a/docs/changelog.rst b/docs/changelog.rst index 3003775798..b83168f327 100644 --- a/docs/changelog.rst +++ b/docs/changelog.rst @@ -17,6 +17,9 @@ Fixes: * :doc:`/plugins/lastgenre`: Fix a bug that prevented tag popularity from being considered. Thanks to :user:`svoos`. :bug:`1559` +* Fixed a bug where plugins wouldn't be notified of the deletion of an item's + art, for example with the ``clearart`` command from the + :doc:`/plugins/embedart`. Thanks to :user:`nathdwek`. :bug:`1565` 1.3.14 (August 2, 2015)