Skip to content

Commit

Permalink
albumtype: improve matching albumtype in the description
Browse files Browse the repository at this point in the history
  • Loading branch information
snejus committed Dec 10, 2024
1 parent 4818788 commit c531ce0
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion beetsplug/bandcamp/metaguru.py
Original file line number Diff line number Diff line change
Expand Up @@ -352,7 +352,10 @@ def _search_albumtype(self, word: str) -> bool:

word_pat = re.compile(rf"(?<!-)\b{word}(\b|\.)", re.I)
in_catnum = re.compile(rf"{word}\d", re.I)
release_ref = re.compile(rf"\b(this[\w\s]*?|the) {word}\b", re.I)
release_ref = re.compile(
rf"\b((this|with|present|deliver|new)[\w\s,'-]*?|the|track|full|first) {word}\b",
re.I,
)
album_name = self.album_name.lower()

media_word_pat = re.compile(rf"(vinyl |x|[0-5]){word}\b", re.I)
Expand Down

0 comments on commit c531ce0

Please sign in to comment.