diff --git a/discord/invite.go b/discord/invite.go index 36bc7c74..3dd15129 100644 --- a/discord/invite.go +++ b/discord/invite.go @@ -22,7 +22,6 @@ type Invite struct { Code string `json:"code"` Guild *InviteGuild `json:"guild"` Channel *InviteChannel `json:"channel"` - ChannelID snowflake.ID `json:"channel_id"` Inviter *User `json:"inviter"` TargetUser *User `json:"target_user"` TargetType InviteTargetType `json:"target_user_type"` diff --git a/rest/invites.go b/rest/invites.go index 5416c455..20a46c81 100644 --- a/rest/invites.go +++ b/rest/invites.go @@ -16,8 +16,8 @@ type Invites interface { GetInvite(code string, opts ...RequestOpt) (*discord.Invite, error) CreateInvite(channelID snowflake.ID, inviteCreate discord.InviteCreate, opts ...RequestOpt) (*discord.Invite, error) DeleteInvite(code string, opts ...RequestOpt) (*discord.Invite, error) - GetGuildInvites(guildID snowflake.ID, opts ...RequestOpt) ([]discord.Invite, error) - GetChannelInvites(channelID snowflake.ID, opts ...RequestOpt) ([]discord.Invite, error) + GetGuildInvites(guildID snowflake.ID, opts ...RequestOpt) ([]discord.ExtendedInvite, error) + GetChannelInvites(channelID snowflake.ID, opts ...RequestOpt) ([]discord.ExtendedInvite, error) } type inviteImpl struct { @@ -39,12 +39,12 @@ func (s *inviteImpl) DeleteInvite(code string, opts ...RequestOpt) (invite *disc return } -func (s *inviteImpl) GetGuildInvites(guildID snowflake.ID, opts ...RequestOpt) (invites []discord.Invite, err error) { +func (s *inviteImpl) GetGuildInvites(guildID snowflake.ID, opts ...RequestOpt) (invites []discord.ExtendedInvite, err error) { err = s.client.Do(GetGuildInvites.Compile(nil, guildID), nil, &invites, opts...) return } -func (s *inviteImpl) GetChannelInvites(channelID snowflake.ID, opts ...RequestOpt) (invites []discord.Invite, err error) { +func (s *inviteImpl) GetChannelInvites(channelID snowflake.ID, opts ...RequestOpt) (invites []discord.ExtendedInvite, err error) { err = s.client.Do(GetChannelInvites.Compile(nil, channelID), nil, &invites, opts...) return }