Skip to content
This repository was archived by the owner on Jul 1, 2022. It is now read-only.

Commit b443225

Browse files
committed
ia-tntvillage: Use a negative lookbehind to keep matching "&"
Better not to exclude "Sperling & Kupfer".
1 parent 3eff9b9 commit b443225

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ia-tntvillage.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ def getyear(self, title, description):
8989
year = year.group(0)
9090
return year
9191
if not year:
92-
years = re.findall(r'\b(?:Anno|Data|Editore|Edizione|Released?|Uscita|Prima uscita|Collana|Titolo|Pubblicazione)\b[^{&]{0,30}\b([0-9]{4}\b)', description, flags=re.S)
92+
years = re.findall(r'\b(?:Anno|Data|Editore|Edizione|Released?|Uscita|Prima uscita|Collana|Titolo|Pubblicazione)\b[^{]{0,30}\b(?<!#)([0-9]{4}\b)', description, flags=re.S)
9393
print(years)
9494
if years:
9595
return years[0]

0 commit comments

Comments
 (0)