This commit is contained in:
Kovid Goyal 2011-04-17 11:21:02 -06:00
parent 305f5a8acb
commit 0f3f855da7

View File

@ -298,6 +298,9 @@ class Source(Plugin):
[ [
# Remove things like: (2010) (Omnibus) etc. # Remove things like: (2010) (Omnibus) etc.
(r'(?i)[({\[](\d{4}|omnibus|anthology|hardcover|paperback|mass\s*market|edition|ed\.)[\])}]', ''), (r'(?i)[({\[](\d{4}|omnibus|anthology|hardcover|paperback|mass\s*market|edition|ed\.)[\])}]', ''),
# Remove any strings that contain the substring edition inside
# parentheses
(r'(?i)[({\[].*?(edition|ed.).*?[\]})]', ''),
# Remove commas used a separators in numbers # Remove commas used a separators in numbers
(r'(\d+),(\d+)', r'\1\2'), (r'(\d+),(\d+)', r'\1\2'),
# Remove hyphens only if they have whitespace before them # Remove hyphens only if they have whitespace before them