Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Add Icon size parameter to GetGuildIconUrl CDN method #2832

Merged
merged 3 commits into from
Feb 24, 2024

Conversation

Misha-133
Copy link
Member

This PR adds a size parameter to the GetGuildIconUrl CDN method

@@ -102,11 +102,12 @@ public static string GetDefaultUserAvatarUrl(ulong userId)
/// </summary>
/// <param name="guildId">The guild snowflake identifier.</param>
/// <param name="iconId">The icon identifier.</param>
/// <param name="size">The size of the image to return in horizontal pixels. This can be any power of two between 16 and 2048.</param>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be any power of two between 16 and 2048.

Should we add a check for this instead of blindly adding it as the size param?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's the same behavior as in all other endpoints that have a size parameter

@Misha-133 Misha-133 merged commit eb5678a into discord-net:dev Feb 24, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants