Skip to content

Commit

Permalink
fix(User): remove fetchFlags()
Browse files Browse the repository at this point in the history
#8755 djs v15.0.0
  • Loading branch information
aiko-chan-ai committed Oct 27, 2024
1 parent c071782 commit 35596b9
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 21 deletions.
10 changes: 0 additions & 10 deletions src/managers/UserManager.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,16 +99,6 @@ class UserManager extends CachedManager {
return this._add(data, cache);
}

/**
* Fetches a user's flags.
* @param {UserResolvable} user The UserResolvable to identify
* @param {BaseFetchOptions} [options] Additional options for this fetch
* @returns {Promise<UserFlags>}
*/
async fetchFlags(user, options) {
return (await this.fetch(user, options)).flags;
}

/**
* Sends a message to a user.
* @param {UserResolvable} user The UserResolvable to identify
Expand Down
9 changes: 0 additions & 9 deletions src/structures/User.js
Original file line number Diff line number Diff line change
Expand Up @@ -388,15 +388,6 @@ class User extends Base {
);
}

/**
* Fetches this user's flags.
* @param {boolean} [force=false] Whether to skip the cache check and request the API
* @returns {Promise<UserFlags>}
*/
fetchFlags(force = false) {
return this.client.users.fetchFlags(this.id, { force });
}

/**
* Fetches this user.
* @param {boolean} [force=true] Whether to skip the cache check and request the API
Expand Down
2 changes: 0 additions & 2 deletions typings/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3472,7 +3472,6 @@ export class User extends PartialTextBasedChannel(Base) {
public displayAvatarURL(options?: ImageURLOptions): string;
public equals(user: User): boolean;
public fetch(force?: boolean): Promise<User>;
public fetchFlags(force?: boolean): Promise<UserFlags>;
public setNote(note: string | null | undefined): Promise<this>;
public toString(): UserMention;
public getProfile(guildId?: Snowflake): Promise<any>;
Expand Down Expand Up @@ -4651,7 +4650,6 @@ export class UserManager extends CachedManager<Snowflake, User, UserResolvable>
public createDM(user: UserResolvable, options?: BaseFetchOptions): Promise<DMChannel>;
public deleteDM(user: UserResolvable): Promise<DMChannel>;
public fetch(user: UserResolvable, options?: BaseFetchOptions): Promise<User>;
public fetchFlags(user: UserResolvable, options?: BaseFetchOptions): Promise<UserFlags>;
public send(user: UserResolvable, options: string | MessagePayload | MessageOptions): Promise<Message>;
}

Expand Down

0 comments on commit 35596b9

Please sign in to comment.