Fix regression in #5378 (#5379)

This commit is contained in:
Josh Roy 2023-06-03 18:13:09 -04:00 committed by GitHub
parent 8d07c4bb0f
commit 8b2c7d7ad1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -383,7 +383,7 @@ public class KeywordReplacer implements IText {
if (this.replaceSpacesWithUnderscores) {
// Don't replace spaces with underscores in command nor escape underscores.
if (line.startsWith("/")) {
if (!line.startsWith("/")) {
replacer = replacer.replace("_", "\\_").replaceAll("\\s", "_");
}
}