Skip to content

Commit

Permalink
fix(Guild): setChannelPositions null parenting (#5841)
Browse files Browse the repository at this point in the history
  • Loading branch information
monbrey committed Jun 13, 2021
1 parent 77c1f15 commit 01a1fd6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/structures/Guild.js
Expand Up @@ -1141,7 +1141,7 @@ class Guild extends BaseGuild {
id: this.client.channels.resolveID(r.channel),
position: r.position,
lock_permissions: r.lockPermissions,
parent_id: this.channels.resolveID(r.parent),
parent_id: typeof r.parent !== 'undefined' ? this.channels.resolveID(r.parent) : undefined,
}));

return this.client.api
Expand Down
2 changes: 1 addition & 1 deletion typings/index.d.ts
Expand Up @@ -2596,7 +2596,7 @@ declare module 'discord.js' {
interface ChannelPosition {
channel: ChannelResolvable;
lockPermissions?: boolean;
parent?: CategoryChannelResolvable;
parent?: CategoryChannelResolvable | null;
position?: number;
}

Expand Down

0 comments on commit 01a1fd6

Please sign in to comment.