From 9382c87dd53da7e6967bf4b46decfcd23a340f59 Mon Sep 17 00:00:00 2001 From: retgal Date: Sun, 7 Jan 2024 13:02:02 +0100 Subject: [PATCH] Improve regex --- src/main/java/mpo/dayon/common/Runner.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/mpo/dayon/common/Runner.java b/src/main/java/mpo/dayon/common/Runner.java index 6abf5c9e..23e6a3ae 100644 --- a/src/main/java/mpo/dayon/common/Runner.java +++ b/src/main/java/mpo/dayon/common/Runner.java @@ -154,7 +154,7 @@ static Map parsePresetFileContent(File presetFile) { static String parseValue(String[] s) { StringBuilder sb = new StringBuilder(); for (int i = 1; i < s.length; i++) { - sb.append(s[i].trim().replaceAll("(^[\"']|[\"']$)", "")).append(":"); + sb.append(s[i].trim().replaceAll("(^[\"'])|([\"']$)", "")).append(":"); } return sb.deleteCharAt(sb.length()-1).toString(); }