Update lastgenre docstring and remove misleading comment (ref https://github.com/beetbox/beets/pull/6169#issuecomment-3716893013)

This commit is contained in:
dunkla 2026-01-10 15:39:40 +01:00
parent c0f3800527
commit e68f1e6c31

View file

@ -331,14 +331,12 @@ class LastGenrePlugin(plugins.BeetsPlugin):
return tags
def _get_existing_genres(self, obj: LibModel) -> list[str]:
"""Return a list of genres for this Item or Album. Empty string genres
are removed."""
"""Return a list of genres for this Item or Album."""
if isinstance(obj, library.Item):
genres_list = obj.get("genres", with_album=False)
else:
genres_list = obj.get("genres")
# Filter out empty strings
return genres_list
def _combine_resolve_and_log(