aboutsummaryrefslogtreecommitdiff
path: root/webAO
diff options
context:
space:
mode:
authorstonedDiscord <Tukz@gmx.de>2023-01-08 20:37:36 +0100
committerstonedDiscord <Tukz@gmx.de>2023-01-08 20:37:36 +0100
commit3cf9a4e0744dbf14dc1dd17d33d9f58478995b2b (patch)
tree7523eea0e05d70e6a7d60b577ea0338e39e662a0 /webAO
parent8c7b3aa3728853b0eeec11bac66d7ffdd961775d (diff)
replace all occurences
Diffstat (limited to 'webAO')
-rw-r--r--webAO/encoding.ts16
1 files changed, 8 insertions, 8 deletions
diff --git a/webAO/encoding.ts b/webAO/encoding.ts
index 2d1f66f..5e53340 100644
--- a/webAO/encoding.ts
+++ b/webAO/encoding.ts
@@ -4,10 +4,10 @@
*/
export function escapeChat(estring: string): string {
return estring
- .replace('#', '<num>')
- .replace('&', '<and>')
- .replace('%', '<percent>')
- .replace('$', '<dollar>');
+ .replaceAll('#', '<num>')
+ .replaceAll('&', '<and>')
+ .replaceAll('%', '<percent>')
+ .replaceAll('$', '<dollar>');
}
/**
@@ -16,10 +16,10 @@ export function escapeChat(estring: string): string {
*/
export function unescapeChat(estring: string): string {
return estring
- .replace('<num>', '#')
- .replace('<and>', '&')
- .replace('<percent>', '%')
- .replace('<dollar>', '$');
+ .replaceAll('<num>', '#')
+ .replaceAll('<and>', '&')
+ .replaceAll('<percent>', '%')
+ .replaceAll('<dollar>', '$');
}
/**