From 76ecf9185bf30dfd624f399b326275ab95d586c1 Mon Sep 17 00:00:00 2001 From: mrcstan Date: Mon, 8 Nov 2021 20:43:46 -0800 Subject: [PATCH] Use regexp to remove non-ASCII, control and non-printable characters from DOI Squash commits before pulling from origin Squash all commits for this branch --- src/main/java/org/jabref/model/entry/identifier/DOI.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/org/jabref/model/entry/identifier/DOI.java b/src/main/java/org/jabref/model/entry/identifier/DOI.java index c666994ff28..6cf677771ca 100644 --- a/src/main/java/org/jabref/model/entry/identifier/DOI.java +++ b/src/main/java/org/jabref/model/entry/identifier/DOI.java @@ -113,7 +113,7 @@ public DOI(String doi) { trimmedDoi = trimmedDoi.replaceAll("[\\p{Cntrl}&&[^\r\n\t]]", ""); // removes non-printable characters from Unicode trimmedDoi = trimmedDoi.replaceAll("\\p{C}", ""); - + // HTTP URL decoding if (doi.matches(HTTP_EXP) || doi.matches(SHORT_DOI_HTTP_EXP)) { try {