fedimbed: flip variables on .test()
This commit is contained in:
parent
bd8e92289c
commit
66a1a873c9
1 changed files with 1 additions and 1 deletions
|
@ -556,7 +556,7 @@ events.add("messageCreate", "fedimbed", async function (msg) {
|
||||||
if (URLS_REGEX.test(msg.content)) {
|
if (URLS_REGEX.test(msg.content)) {
|
||||||
const urls = msg.content.match(URLS_REGEX);
|
const urls = msg.content.match(URLS_REGEX);
|
||||||
for (let url of urls) {
|
for (let url of urls) {
|
||||||
const hasSpoiler = url.test(SPOILER_REGEX);
|
const hasSpoiler = SPOILER_REGEX.test(url);
|
||||||
url = url.replace(/\|/g,"").trim().replace("@\u200b", "@").replace("@%E2%80%8B", "@");
|
url = url.replace(/\|/g,"").trim().replace("@\u200b", "@").replace("@%E2%80%8B", "@");
|
||||||
for (const service of Object.keys(PATH_REGEX)) {
|
for (const service of Object.keys(PATH_REGEX)) {
|
||||||
const regex = PATH_REGEX[service];
|
const regex = PATH_REGEX[service];
|
||||||
|
|
Loading…
Reference in a new issue