Update embedCheck.ts

Update regex to escape special character .
This commit is contained in:
Lucid Kobold
2025-07-03 22:51:31 -04:00
committed by GitHub
parent 6a0724e60f
commit e28aa399e5

View File

@@ -27,11 +27,11 @@ feature.on(
if (embeds.length) {
const metaLinks = embeds.filter(({ url }) =>
url.match(
/(facebook.com|meta.com|instagram.com|threads.net|whatsapp.com)/gi
/(facebook\.com|meta\.com|instagram\.com|threads\.net|whatsapp\.com)/gi
)
);
const twitterLinks = embeds.filter(({ url }) =>
url.match(/(x.com|twitter.com)/gi)
url.match(/(x\.com|twitter\.com)/gi)
);
if (metaLinks.length && twitterLinks.length) {