Optimize Game slug generator by using cached RegEx

This commit is contained in:
redphx
2024-10-22 20:07:26 +07:00
parent 33c3b2810a
commit 8a3d48d4a3
3 changed files with 24 additions and 0 deletions

View File

@@ -144,4 +144,10 @@ export const BxExposed = {
return false;
},
GameSlugRegexes: [
/[;,/?:@&=+_`~$%#^*()!^\u2122\xae\xa9]/g,
/ {2,}/g,
/ /g,
],
};