Why is ActivityType.Custom excluded from the presence ActivityOptions[]?

See code here in index.d.ts:
export interface ActivityOptions {
name?: string;
url?: string;
type?: Exclude<ActivityType, ActivityType.Custom>;
shardId?: number | readonly number[];
}
export interface ActivityOptions {
name?: string;
url?: string;
type?: Exclude<ActivityType, ActivityType.Custom>;
shardId?: number | readonly number[];
}
Solution:
Update: the exclusion has been removed and typescript is no longer mad at me. ```ts export interface ActivityOptions { name: string; state?: string;...
Jump to solution
3 Replies
Favna
Favna4mo ago
This is not sapphire related. These types come from DiscordJS. Bots cannot have custom statuses.
moosee
mooseeOP4mo ago
That must've changed recently as all of my bots have had custom statuses for the last 8 or so months
Solution
moosee
moosee4mo ago
Update: the exclusion has been removed and typescript is no longer mad at me.
export interface ActivityOptions {
name: string;
state?: string;
url?: string;
type?: ActivityType;
shardId?: number | readonly number[];
}
export interface ActivityOptions {
name: string;
state?: string;
url?: string;
type?: ActivityType;
shardId?: number | readonly number[];
}
Very confusing what that was all about! The bots worked fine either way but I never like seeing red in my IDE
Want results from more Discord servers?
Add your server