mirror of
https://github.com/beetbox/beets.git
synced 2026-02-24 00:02:20 +01:00
fetchart: fixup #5244
by restoring config validation and making things more Pythonic
This commit is contained in:
parent
f6f5518a7f
commit
395aec96a3
1 changed files with 2 additions and 2 deletions
|
|
@ -1295,7 +1295,7 @@ class FetchArtPlugin(plugins.BeetsPlugin, RequestMixin):
|
|||
|
||||
@staticmethod
|
||||
def _is_source_file_removal_enabled():
|
||||
return config["import"]["delete"] or config["import"]["move"]
|
||||
return config["import"]["delete"].get(bool) or config["import"]["move"].get(bool)
|
||||
|
||||
# Asynchronous; after music is added to the library.
|
||||
def fetch_art(self, session, task):
|
||||
|
|
@ -1339,7 +1339,7 @@ class FetchArtPlugin(plugins.BeetsPlugin, RequestMixin):
|
|||
"""Place the discovered art in the filesystem."""
|
||||
if task in self.art_candidates:
|
||||
candidate = self.art_candidates.pop(task)
|
||||
removal_enabled = FetchArtPlugin._is_source_file_removal_enabled()
|
||||
removal_enabled = self._is_source_file_removal_enabled()
|
||||
|
||||
self._set_art(task.album, candidate, not removal_enabled)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue