mirror of
https://github.com/beetbox/beets.git
synced 2026-01-04 23:12:51 +01:00
avoid loading a "phantom" plugin
I'm not sure when this was introduced, but "beet version" could list a plugin called "plugins" because the load_plugins function would pick up the BeetsPlugin class itself. This was benign but confusing.
This commit is contained in:
parent
a23b685747
commit
2f5165d4e1
1 changed files with 2 additions and 1 deletions
|
|
@ -171,7 +171,8 @@ def load_plugins(names=()):
|
|||
raise
|
||||
else:
|
||||
for obj in getattr(namespace, name).__dict__.values():
|
||||
if isinstance(obj, type) and issubclass(obj, BeetsPlugin):
|
||||
if isinstance(obj, type) and issubclass(obj, BeetsPlugin) \
|
||||
and obj != BeetsPlugin:
|
||||
_classes.add(obj)
|
||||
|
||||
except:
|
||||
|
|
|
|||
Loading…
Reference in a new issue