fedimbed: Shocking! The most annoying person you know finally makes you implement a permission check.
This commit is contained in:
parent
b66568e546
commit
f6f3f2654e
1 changed files with 2 additions and 0 deletions
|
|
@ -1613,6 +1613,8 @@ events.add("messageCreate", "fedimbed", async function (msg) {
|
|||
if (!((await hasFlag(msg.guildID, "fedimbed")) || (await hasFlag(msg.guildID, "bskyEmbeds")))) return;
|
||||
if (!msg.content || msg.content == "") return;
|
||||
|
||||
if (!msg.member.permissions.has("embedLinks")) return;
|
||||
|
||||
if (URLS_REGEX.test(msg.content)) {
|
||||
const urls = msg.content.match(URLS_REGEX);
|
||||
for (let url of urls) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue