aboutsummaryrefslogtreecommitdiff
path: root/src/plugins/nitroBypass.ts
diff options
context:
space:
mode:
authorArjixWasTaken <53124886+ArjixWasTaken@users.noreply.github.com>2022-10-06 01:11:32 +0300
committerGitHub <noreply@github.com>2022-10-06 00:11:32 +0200
commite563521416052808bcec57057b921f0c0b6ca594 (patch)
tree6e0e116c7377bf5417b0be119f10316bc4cab998 /src/plugins/nitroBypass.ts
parenta9e67aa3400075ec4fb2fe6d59d006bae8981f0c (diff)
downloadVencord-e563521416052808bcec57057b921f0c0b6ca594.tar.gz
Vencord-e563521416052808bcec57057b921f0c0b6ca594.tar.bz2
Vencord-e563521416052808bcec57057b921f0c0b6ca594.zip
Add commands API (#38)
Diffstat (limited to 'src/plugins/nitroBypass.ts')
-rw-r--r--src/plugins/nitroBypass.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/nitroBypass.ts b/src/plugins/nitroBypass.ts
index 4a0ed44..d96ff0d 100644
--- a/src/plugins/nitroBypass.ts
+++ b/src/plugins/nitroBypass.ts
@@ -61,7 +61,7 @@ export default definePlugin({
const emojiString = `<${emoji.animated ? 'a' : ''}:${emoji.originalName || emoji.name}:${emoji.id}>`;
const url = emoji.url.replace(/\?size=[0-9]+/, `?size=48`);
messageObj.content = messageObj.content.replace(emojiString, (match, offset, origStr) => {
- return `${getWordBoundary(origStr, offset-1)}${url}${getWordBoundary(origStr, offset+match.length)}`;
+ return `${getWordBoundary(origStr, offset - 1)}${url}${getWordBoundary(origStr, offset + match.length)}`;
});
}
});
@@ -76,7 +76,7 @@ export default definePlugin({
const url = emoji.url.replace(/\?size=[0-9]+/, `?size=48`);
messageObj.content = messageObj.content.replace(emojiStr, (match, offset, origStr) => {
- return `${getWordBoundary(origStr, offset-1)}${url}${getWordBoundary(origStr, offset+match.length)}`;
+ return `${getWordBoundary(origStr, offset - 1)}${url}${getWordBoundary(origStr, offset + match.length)}`;
});
}
});