Skip to content

Commit dcee09c

Browse files
monbreySpaceEEC
authored andcommitted
backport(Permissions): backport STREAM permission from #3309 (#3447)
* Backport the STREAM permission * Update typings and default
1 parent 1121b2f commit dcee09c

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

src/util/Permissions.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,7 @@ class Permissions {
208208
* - `ADD_REACTIONS` (add new reactions to messages)
209209
* - `VIEW_AUDIT_LOG`
210210
* - `PRIORITY_SPEAKER`
211+
* - `STREAM`
211212
* - `VIEW_CHANNEL`
212213
* - `READ_MESSAGES` **(deprecated)**
213214
* - `SEND_MESSAGES`
@@ -244,6 +245,7 @@ Permissions.FLAGS = {
244245
ADD_REACTIONS: 1 << 6,
245246
VIEW_AUDIT_LOG: 1 << 7,
246247
PRIORITY_SPEAKER: 1 << 8,
248+
STREAM: 1 << 9,
247249

248250
VIEW_CHANNEL: 1 << 10,
249251
READ_MESSAGES: 1 << 10,
@@ -282,7 +284,7 @@ Permissions.ALL = Object.keys(Permissions.FLAGS).reduce((all, p) => all | Permis
282284
* Bitfield representing the default permissions for users
283285
* @type {number}
284286
*/
285-
Permissions.DEFAULT = 104324097;
287+
Permissions.DEFAULT = 104324673;
286288

287289
/**
288290
* @class EvaluatedPermissions

typings/index.d.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1997,6 +1997,7 @@ declare module 'discord.js' {
19971997
ADD_REACTIONS?: number;
19981998
VIEW_AUDIT_LOG?: number;
19991999
PRIORITY_SPEAKER?: number;
2000+
STREAM?: number;
20002001
VIEW_CHANNEL?: number;
20012002
READ_MESSAGES?: number;
20022003
SEND_MESSAGES?: number;
@@ -2032,6 +2033,7 @@ declare module 'discord.js' {
20322033
ADD_REACTIONS?: boolean;
20332034
VIEW_AUDIT_LOG?: boolean;
20342035
PRIORITY_SPEAKER?: boolean;
2036+
STREAM?: boolean;
20352037
VIEW_CHANNEL?: boolean;
20362038
READ_MESSAGES?: boolean;
20372039
SEND_MESSAGES?: boolean;
@@ -2066,6 +2068,7 @@ declare module 'discord.js' {
20662068
| 'ADD_REACTIONS'
20672069
| 'VIEW_AUDIT_LOG'
20682070
| 'PRIORITY_SPEAKER'
2071+
| 'STREAM'
20692072
| 'VIEW_CHANNEL'
20702073
| 'READ_MESSAGES'
20712074
| 'SEND_MESSAGES'

0 commit comments

Comments
 (0)