add all whitespaces in regex

This commit is contained in:
M. Dietrich 2014-09-02 01:16:33 +02:00
parent 546082147a
commit a7b3aa343e

View File

@ -561,7 +561,7 @@ public class UIHelper {
{"\\^\\^", " 😁 ", },
}) {
String p = r[0];
p = "(^" + p + "$|^" + p + " +| +" + p + " +| +" + p + "$)";
p = "(^" + p + "$|^" + p + "\\s+|\\s+" + p + "\\s+|\\s+" + p + "$)";
body = body.replaceAll(p, r[1]);
}
body = body.trim();