Skip to content

Commit

Permalink
fix: pass force correctly (#7721)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jiralite committed Apr 5, 2022
1 parent 3b3dabf commit 402514f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/discord.js/src/structures/DMChannel.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ class DMChannel extends Channel {
* @returns {Promise<DMChannel>}
*/
fetch(force = true) {
return this.client.users.createDM(this.recipientId, force);
return this.client.users.createDM(this.recipientId, { force });
}

/**
Expand Down
2 changes: 1 addition & 1 deletion packages/discord.js/src/structures/User.js
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@ class User extends Base {
* @returns {Promise<DMChannel>}
*/
createDM(force = false) {
return this.client.users.createDM(this.id, force);
return this.client.users.createDM(this.id, { force });
}

/**
Expand Down

0 comments on commit 402514f

Please sign in to comment.