Be more lenient with parentheses

This commit is contained in:
Panupong Pasupat 2017-08-29 04:27:56 -07:00
parent f57d5c16b1
commit f78d1c77c1
1 changed files with 1 additions and 1 deletions

View File

@ -362,7 +362,7 @@ public final class StringNormalizationUtils {
// Remove citations
string = string.trim().replaceAll("((?<!^)\\[[^\\]]*\\]|\\[\\d+\\]|[•♦†‡*#+])*$", "");
// Remove details in parenthesis
string = string.trim().replaceAll("(?<!^)(\\s+\\([^)]*\\))*$", "");
string = string.trim().replaceAll("(?<!^)(\\s*\\([^)]*\\))*$", "");
// Remove outermost quotation mark
string = string.trim().replaceAll("^\"([^\"]*)\"$", "$1");
} while (!oldString.equals(string));