Recognize 👍

This commit is contained in:
Midgard 2022-06-20 14:16:35 +02:00
parent 6e8e33f2c5
commit dcb0c789d2
Signed by: midgard
GPG key ID: 511C112F1331BBB4

View file

@ -1,6 +1,6 @@
function transformMessageText(message) {
return message
.split(/(?<=:|\W|^)(:[a-z0-9_-]+:)(?=:|\W|$)/)
.split(/(?<=:|\W|^)(:[a-z0-9_+-]+:)(?=:|\W|$)/)
.map((x, i) => i % 2
? emoji[x.slice(1, -1)] || x
: x)