mirror of
https://github.com/beetbox/beets.git
synced 2026-01-24 09:01:24 +01:00
Fix usage of embedart by convert plugin
Instanciation of EmbedCovertArtPlugin on the fly: there may be several instances → problem with the listeners it registers?
This commit is contained in:
parent
30562024d2
commit
f504c78681
1 changed files with 3 additions and 2 deletions
|
|
@ -23,7 +23,7 @@ from string import Template
|
||||||
|
|
||||||
from beets import ui, util, plugins, config
|
from beets import ui, util, plugins, config
|
||||||
from beets.plugins import BeetsPlugin
|
from beets.plugins import BeetsPlugin
|
||||||
from beetsplug.embedart import embed_item
|
from beetsplug.embedart import EmbedCoverArtPlugin
|
||||||
from beets.util.confit import ConfigTypeError
|
from beets.util.confit import ConfigTypeError
|
||||||
|
|
||||||
_fs_lock = threading.Lock()
|
_fs_lock = threading.Lock()
|
||||||
|
|
@ -283,7 +283,8 @@ class ConvertPlugin(BeetsPlugin):
|
||||||
if config['convert']['embed']:
|
if config['convert']['embed']:
|
||||||
album = item.get_album()
|
album = item.get_album()
|
||||||
if album and album.artpath:
|
if album and album.artpath:
|
||||||
embed_item(item, album.artpath, itempath=converted)
|
EmbedCoverArtPlugin().embed_item(item, album.artpath,
|
||||||
|
itempath=converted)
|
||||||
|
|
||||||
if keep_new:
|
if keep_new:
|
||||||
plugins.send('after_convert', item=item,
|
plugins.send('after_convert', item=item,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue