mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-16 19:43:29 +01:00
fix(Client): spelling of InvalidScopesWithPermissions
This commit is contained in:
@@ -421,7 +421,7 @@ class Client extends BaseClient {
|
|||||||
throw new DiscordjsTypeError(ErrorCodes.InvalidMissingScopes);
|
throw new DiscordjsTypeError(ErrorCodes.InvalidMissingScopes);
|
||||||
}
|
}
|
||||||
if (scopes.some(scope => ![OAuth2Scopes.Bot].includes(scope)) && options.permissions) {
|
if (scopes.some(scope => ![OAuth2Scopes.Bot].includes(scope)) && options.permissions) {
|
||||||
throw new DiscordjsTypeError(ErrorCodes.InvalidScopeWithPermissions);
|
throw new DiscordjsTypeError(ErrorCodes.InvalidScopesWithPermissions);
|
||||||
}
|
}
|
||||||
const validScopes = Object.values(OAuth2Scopes);
|
const validScopes = Object.values(OAuth2Scopes);
|
||||||
const invalidScope = scopes.find(scope => !validScopes.includes(scope));
|
const invalidScope = scopes.find(scope => !validScopes.includes(scope));
|
||||||
|
|||||||
Reference in New Issue
Block a user