From 50b5ce75614055f504c731a9d6c857668be6de50 Mon Sep 17 00:00:00 2001 From: Antonin Delpeuch Date: Fri, 22 Feb 2019 18:04:03 +0000 Subject: [PATCH] More robust replacement condition in Wikidata summaries --- .../wikidata/operations/PerformWikibaseEditsOperation.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/extensions/wikidata/src/org/openrefine/wikidata/operations/PerformWikibaseEditsOperation.java b/extensions/wikidata/src/org/openrefine/wikidata/operations/PerformWikibaseEditsOperation.java index 833c701b8..eb880c7b5 100644 --- a/extensions/wikidata/src/org/openrefine/wikidata/operations/PerformWikibaseEditsOperation.java +++ b/extensions/wikidata/src/org/openrefine/wikidata/operations/PerformWikibaseEditsOperation.java @@ -173,7 +173,7 @@ public class PerformWikibaseEditsOperation extends EngineDependentOperation { // Because commas and colons are used by Wikibase to separate the auto-generated summaries // from the user-supplied ones, we replace these separators by similar unicode characters to // make sure they can be told apart. - String summaryWithoutCommas = _summary.replace(",","ꓹ").replace(":","։"); + String summaryWithoutCommas = _summary.replaceAll(", ","ꓹ ").replaceAll(": ","։ "); String summary = summaryWithoutCommas + String.format(" ([[:toollabs:editgroups/b/OR/%s|details]])", (Long.toHexString(token).substring(0, 9)));