From 6f2d66ce4acba669fc1bc62655941fd0f05a947c Mon Sep 17 00:00:00 2001 From: Flam3rboy <34555296+Flam3rboy@users.noreply.github.com> Date: Sat, 22 May 2021 16:12:46 +0200 Subject: [PATCH] :sparkles: system user permissions --- src/util/Permissions.ts | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/util/Permissions.ts b/src/util/Permissions.ts index d358851c..b2af93e0 100644 --- a/src/util/Permissions.ts +++ b/src/util/Permissions.ts @@ -149,6 +149,8 @@ export class Permissions extends BitField { owner_id?: string; }; }) { + if (user.id === "0") return new Permissions("ADMINISTRATOR"); // system user id + let roles = guild.roles.filter((x) => user.roles.includes(x.id)); let permission = Permissions.rolePermission(roles);