hf: replace all ">" and "<" in username (#37)

This commit is contained in:
Aidan 2025-04-14 23:37:59 -04:00 committed by GitHub
parent 7120644945
commit 4e4232c45e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -199,7 +199,7 @@ module.exports = (bot) => {
let userName = String(ctx.from.first_name); let userName = String(ctx.from.first_name);
if(userName.includes("<") && userName.includes(">")) { if(userName.includes("<") && userName.includes(">")) {
userName = userName.replace("<", "").replace(">", ""); userName = userName.replaceAll("<", "").replaceAll(">", "");
} }
const phone = ctx.message.text.split(" ").slice(1).join(" "); const phone = ctx.message.text.split(" ").slice(1).join(" ");