fix the conditional

This commit is contained in:
Erkin Alp Güney
2022-03-23 22:25:46 +03:00
committed by GitHub
parent 02f3b253fd
commit ea0fbf12fb

View File

@@ -212,7 +212,7 @@ export class Channel extends BaseClass {
...channel,
...(!opts?.keepId && { id: Snowflake.generate() }),
created_at: new Date(),
position: ((channel.type === ChannelType.UNHANDLED) || channel.position) || 0,
position: (channel.type === ChannelType.UNHANDLED ? 0 : channel.position) || 0,
};
await Promise.all([