Soft'N'Design Software
/
projects
/
trivabble.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a604b42
)
correct some eslint issues
author
Laurent Mazet
<mazet@softndesign.org>
Sun, 31 May 2020 23:18:21 +0000
(
01:18
+0200)
committer
Laurent Mazet
<mazet@softndesign.org>
Tue, 9 Jun 2020 20:26:07 +0000
(22:26 +0200)
public/trivabble.js
patch
|
blob
|
blame
|
history
diff --git
a/public/trivabble.js
b/public/trivabble.js
index de8046414788c0960c0f2209dca18b7111787c99..43d571049eff3e702091ec476bb758d82d245872 100644
(file)
--- a/
public/trivabble.js
+++ b/
public/trivabble.js
@@
-1554,8
+1554,12
@@
delete badWords[k];
}
}
- words = words.join(" ").replace(/^ */, "").replace(/ *$/, "");
- badWords = badWords.join(" ").replace(/^ */, "").replace(/ *$/, "");
+ words = words.join(" ")
+ .replace(/^ */u, "")
+ .replace(/ *$/u, "");
+ badWords = badWords.join(" ")
+ .replace(/^ */u, "")
+ .replace(/ *$/u, "");
/* Advice on erroneous spelling */
if (badWords.length > 0) {