Skip to content

Commit

Permalink
fix(Client): omit private properties from toJSON (#8337)
Browse files Browse the repository at this point in the history
  • Loading branch information
SpaceEEC committed Jul 22, 2022
1 parent 74ec7be commit 830c670
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/discord.js/src/client/BaseClient.js
Expand Up @@ -63,7 +63,7 @@ class BaseClient extends EventEmitter {
}

toJSON(...props) {
return flatten(this, { domain: false }, ...props);
return flatten(this, ...props);
}
}

Expand Down
3 changes: 2 additions & 1 deletion packages/discord.js/src/client/Client.js
Expand Up @@ -454,7 +454,8 @@ class Client extends BaseClient {

toJSON() {
return super.toJSON({
readyAt: false,
actions: false,
presence: false,
});
}

Expand Down

0 comments on commit 830c670

Please sign in to comment.