mirror of
https://github.com/discordeno/discordeno.git
synced 2026-06-16 19:28:17 +00:00
fix: createInvite return type
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import { rest } from "../../rest/rest.ts";
|
||||
import type { CreateChannelInvite } from "../../types/invites/create_channel_invite.ts";
|
||||
import type { Invite } from "../../types/invites/invite.ts";
|
||||
import type { InviteMetadata } from "../../types/invites/invite_metadata.ts";
|
||||
import { Errors } from "../../types/discordeno/errors.ts";
|
||||
import { endpoints } from "../../util/constants.ts";
|
||||
import { requireBotChannelPermissions } from "../../util/permissions.ts";
|
||||
@@ -16,5 +16,5 @@ export async function createInvite(channelId: bigint, options: CreateChannelInvi
|
||||
throw new Error(Errors.INVITE_MAX_USES_INVALID);
|
||||
}
|
||||
|
||||
return await rest.runMethod<Invite>("post", endpoints.CHANNEL_INVITES(channelId), options);
|
||||
return await rest.runMethod<InviteMetadata>("post", endpoints.CHANNEL_INVITES(channelId), options);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user