Update edit_channel.ts

This commit is contained in:
ITOH
2021-04-23 23:27:30 +02:00
parent 0d7590349b
commit 7f8e67f5c6
+2 -3
View File
@@ -1,6 +1,7 @@
import { eventHandlers } from "../../bot.ts"; import { eventHandlers } from "../../bot.ts";
import { rest } from "../../rest/rest.ts"; import { rest } from "../../rest/rest.ts";
import { ModifyChannel } from "../../types/channels/modify_channel.ts"; import { ModifyChannel } from "../../types/channels/modify_channel.ts";
import { Channel } from "../../types/mod.ts";
import { endpoints } from "../../util/constants.ts"; import { endpoints } from "../../util/constants.ts";
import { import {
calculateBits, calculateBits,
@@ -58,7 +59,7 @@ export async function editChannel(
}), }),
}; };
const result = await rest.runMethod( return await rest.runMethod<Channel>(
"patch", "patch",
endpoints.CHANNEL_BASE(channelId), endpoints.CHANNEL_BASE(channelId),
{ {
@@ -66,8 +67,6 @@ export async function editChannel(
reason, reason,
}, },
); );
return result;
} }
interface EditChannelRequest { interface EditChannelRequest {