Skip to content

Commit

Permalink
refactor(Channel): make delete async (#6417)
Browse files Browse the repository at this point in the history
  • Loading branch information
NotSugden committed Aug 14, 2021
1 parent 759faa4 commit 71fdf6f
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions src/structures/Channel.js
Original file line number Diff line number Diff line change
Expand Up @@ -93,11 +93,9 @@ class Channel extends Base {
* .then(console.log)
* .catch(console.error);
*/
delete() {
return this.client.api
.channels(this.id)
.delete()
.then(() => this);
async delete() {
await this.client.api.channels(this.id).delete();
return this;
}

/**
Expand Down

0 comments on commit 71fdf6f

Please sign in to comment.