mirror of
https://github.com/discordjs/discord.js.git
synced 2024-08-20 22:54:43 +12:00
fix(ClientUser): Fix modifying self (#9318)
fix(ClientUser): fix modifying
This commit is contained in:
parent
8f12054c06
commit
09ca243c2f
1 changed files with 1 additions and 1 deletions
|
@ -56,7 +56,7 @@ class ClientUser extends User {
|
|||
async edit({ username, avatar }) {
|
||||
const data = await this.client.api
|
||||
.users('@me')
|
||||
.patch({ username, avatar: avatar && (await DataResolver.resolveImage(avatar)) });
|
||||
.patch({ data: { username, avatar: avatar && (await DataResolver.resolveImage(avatar)) } });
|
||||
|
||||
this.client.token = data.token;
|
||||
const { updated } = this.client.actions.UserUpdate.handle(data);
|
||||
|
|
Loading…
Reference in a new issue