Sopur / Discord-user-bots

Working discord user bots library.
MIT License
85 stars 36 forks source link

Error When User Invalid Token #57

Closed iamvinthanks closed 4 months ago

iamvinthanks commented 9 months ago

When I use client = new Discord.Client(token);

and when token is invalid got message

discord-user-bots\src\client\client.js:58 } else throw new DiscordAPIError(`Discord rejected token "${token}" (Not valid)`);
DiscordAPIError: Discord API Error: Discord rejected token "XXXXxxxxx" (Not valid)

How to handle this error?

Sopur commented 4 months ago

Just added this feature in the 2.0.0 update. DUB now works just like Discord.js, with a ".login" method.