mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-13 01:53:30 +01:00
feat(Integration): add scopes (#8483)
This commit is contained in:
@@ -185,6 +185,16 @@ class Integration extends Base {
|
|||||||
} else {
|
} else {
|
||||||
this.application ??= null;
|
this.application ??= null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ('scopes' in data) {
|
||||||
|
/**
|
||||||
|
* The scopes this application has been authorized for
|
||||||
|
* @type {OAuth2Scopes[]}
|
||||||
|
*/
|
||||||
|
this.scopes = data.scopes;
|
||||||
|
} else {
|
||||||
|
this.scopes ??= [];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
1
packages/discord.js/typings/index.d.ts
vendored
1
packages/discord.js/typings/index.d.ts
vendored
@@ -1450,6 +1450,7 @@ export class Integration extends Base {
|
|||||||
public role: Role | null;
|
public role: Role | null;
|
||||||
public enableEmoticons: boolean | null;
|
public enableEmoticons: boolean | null;
|
||||||
public get roles(): Collection<Snowflake, Role>;
|
public get roles(): Collection<Snowflake, Role>;
|
||||||
|
public scopes: OAuth2Scopes[];
|
||||||
public get syncedAt(): Date | null;
|
public get syncedAt(): Date | null;
|
||||||
public syncedTimestamp: number | null;
|
public syncedTimestamp: number | null;
|
||||||
public syncing: boolean | null;
|
public syncing: boolean | null;
|
||||||
|
|||||||
Reference in New Issue
Block a user