feat(PermissionFlagsBits): add USE_APPLICATION_COMMANDS (#85)

Co-authored-by: Vlad Frangu <kingdgrizzle@gmail.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
This commit is contained in:
Advaith
2021-03-27 09:09:47 -07:00
committed by GitHub
parent ca61396577
commit ceb787ba36
2 changed files with 8 additions and 8 deletions

View File

@@ -7,10 +7,9 @@ import type { Permissions, Snowflake } from '../../common/mod.ts';
/**
* https://discord.com/developers/docs/topics/permissions#permissions-bitwise-permission-flags
*
* These flags are exported as `BigInt`s and NOT numbers. For most of them, you can
* convert them in a number by wrapping it in `Number()`, however be careful as any
* further bits added may cause issues if done so. Try to use BigInts as much as possible
* or modules that can replicate them in some way
* These flags are exported as `BigInt`s and NOT numbers. Wrapping them in `Number()`
* may cause issues, try to use BigInts as much as possible or modules that can
* replicate them in some way
*/
export const PermissionFlagsBits = {
CREATE_INSTANT_INVITE: 1n << 0n,
@@ -44,6 +43,7 @@ export const PermissionFlagsBits = {
MANAGE_ROLES: 1n << 28n,
MANAGE_WEBHOOKS: 1n << 29n,
MANAGE_EMOJIS: 1n << 30n,
USE_APPLICATION_COMMANDS: 1n << 31n,
} as const;
/**

View File

@@ -7,10 +7,9 @@ import type { Permissions, Snowflake } from '../../common/index';
/**
* https://discord.com/developers/docs/topics/permissions#permissions-bitwise-permission-flags
*
* These flags are exported as `BigInt`s and NOT numbers. For most of them, you can
* convert them in a number by wrapping it in `Number()`, however be careful as any
* further bits added may cause issues if done so. Try to use BigInts as much as possible
* or modules that can replicate them in some way
* These flags are exported as `BigInt`s and NOT numbers. Wrapping them in `Number()`
* may cause issues, try to use BigInts as much as possible or modules that can
* replicate them in some way
*/
export const PermissionFlagsBits = {
CREATE_INSTANT_INVITE: 1n << 0n,
@@ -44,6 +43,7 @@ export const PermissionFlagsBits = {
MANAGE_ROLES: 1n << 28n,
MANAGE_WEBHOOKS: 1n << 29n,
MANAGE_EMOJIS: 1n << 30n,
USE_APPLICATION_COMMANDS: 1n << 31n,
} as const;
/**