diff --git a/CHANGELOG.md b/CHANGELOG.md index 35cf1319ab0..cad6b172832 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -27,6 +27,7 @@ We refer to [GitHub issues](https://github.com/JabRef/jabref/issues) by using `# - Fix import of journal title in ris format. [#2506](https://github.com/JabRef/jabref/issues/2506) - We fixed the export of the `number` field in MS-Office XML export. [#2509](https://github.com/JabRef/jabref/issues/2509) - The field `issue` is now always exported to the corresponding `issue` field in MS-Office XML. + - We fixed an issue with repeated escaping of the %-sign when running the LaTeXCleanup more than once. [#2451](https://github.com/JabRef/jabref/issues/2451) ### Removed diff --git a/src/main/java/net/sf/jabref/logic/formatter/bibtexfields/LatexCleanupFormatter.java b/src/main/java/net/sf/jabref/logic/formatter/bibtexfields/LatexCleanupFormatter.java index 58cd51b4a17..ba3b9f6c9d6 100644 --- a/src/main/java/net/sf/jabref/logic/formatter/bibtexfields/LatexCleanupFormatter.java +++ b/src/main/java/net/sf/jabref/logic/formatter/bibtexfields/LatexCleanupFormatter.java @@ -1,10 +1,21 @@ package net.sf.jabref.logic.formatter.bibtexfields; +import java.util.regex.Pattern; + import net.sf.jabref.logic.l10n.Localization; import net.sf.jabref.model.cleanup.Formatter; public class LatexCleanupFormatter implements Formatter { + private static final Pattern REMOVE_REDUNDANT = Pattern + .compile("(?