|
|
@@ -929,13 +929,13 @@ namespace Discord.API |
|
|
|
} |
|
|
|
catch (HttpException ex) when (ex.HttpCode == HttpStatusCode.NotFound) { return null; } |
|
|
|
} |
|
|
|
public async Task<InviteMetadata> GetVanityInviteAsync(ulong guildId, RequestOptions options = null) |
|
|
|
public async Task<InviteVanity> GetVanityInviteAsync(ulong guildId, RequestOptions options = null) |
|
|
|
{ |
|
|
|
Preconditions.NotEqual(guildId, 0, nameof(guildId)); |
|
|
|
options = RequestOptions.CreateOrClone(options); |
|
|
|
|
|
|
|
var ids = new BucketIds(guildId: guildId); |
|
|
|
return await SendAsync<InviteMetadata>("GET", () => $"guilds/{guildId}/vanity-url", ids, options: options).ConfigureAwait(false); |
|
|
|
return await SendAsync<InviteVanity>("GET", () => $"guilds/{guildId}/vanity-url", ids, options: options).ConfigureAwait(false); |
|
|
|
} |
|
|
|
public async Task<IReadOnlyCollection<InviteMetadata>> GetGuildInvitesAsync(ulong guildId, RequestOptions options = null) |
|
|
|
{ |
|
|
|