From 2849958ef0286863da93d9b384b4cb111e2c3c51 Mon Sep 17 00:00:00 2001 From: MattIPv4 Date: Sat, 10 Jul 2021 18:49:01 +0100 Subject: [PATCH] fix(PermissionsOverwrites): only convert type if number --- src/structures/PermissionOverwrites.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/structures/PermissionOverwrites.js b/src/structures/PermissionOverwrites.js index 548bdfdeca4d..ea70d15081d0 100644 --- a/src/structures/PermissionOverwrites.js +++ b/src/structures/PermissionOverwrites.js @@ -36,7 +36,7 @@ class PermissionOverwrites extends Base { * The type of this overwrite * @type {OverwriteType} */ - this.type = OverwriteTypes[data.type]; + this.type = typeof data.type === 'number' ? OverwriteTypes[data.type] : data.type; /** * The permissions that are denied for the user or role.