Home > Net >  TypeError: Discord.Permissions is not a constructor
TypeError: Discord.Permissions is not a constructor

Time:11-21

There’s this error i get after i try to login to discord using my bot’s dashboard: > TypeError: Discord.Permissions is not a constructor

Code:

const _perms = guild.permissions_new;
                const _checkBot = client.guilds.cache.get(guild.id);
                _guilds[index].bot_added = _checkBot ? true : false;
                _guilds[index].permissions = new Discord.Permissions(_perms).toArray();
            });

            delete _user.accessToken;
            _user.permissions = _dbUser ? _dbUser.permissions : [];
            _user.notifications = _dbUser ? _dbUser.notifications : [];
            _user.connections = {};
            _user.guilds = _guilds;

Any help would be appreciated.

  • Related