mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-16 03:18:17 +00:00
1st Review changes
This commit is contained in:
@@ -434,9 +434,7 @@ export async function editChannelOverwrite(
|
||||
throw new Error(Errors.MISSING_MANAGE_CHANNELS);
|
||||
}
|
||||
|
||||
const { allow, deny, ...info } = overwrite;
|
||||
let channel = cache.channels.get(channelID);
|
||||
|
||||
if (!channel) throw new Error(Errors.CHANNEL_NOT_FOUND);
|
||||
|
||||
const payload = {
|
||||
@@ -448,9 +446,9 @@ export async function editChannelOverwrite(
|
||||
deny: rawOverwrite.deny,
|
||||
})),
|
||||
{
|
||||
...info,
|
||||
allow: calculateBits(allow),
|
||||
deny: calculateBits(deny),
|
||||
...overwrite,
|
||||
allow: calculateBits(overwrite.allow),
|
||||
deny: calculateBits(overwrite.deny),
|
||||
},
|
||||
],
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user