feat: user avatar decoration

#9018 djs
This commit is contained in:
March 7th
2023-01-06 18:08:20 +07:00
parent fe7e3b8fda
commit 27dca8890a
3 changed files with 24 additions and 0 deletions

View File

@@ -196,6 +196,8 @@ exports.Endpoints = {
if (dynamic && hash.startsWith('a_')) format = 'gif';
return makeImageUrl(`${root}/avatars/${userId}/${hash}`, { format, size });
},
AvatarDecoration: (userId, hash, format = 'png', size) =>
makeImageUrl(`${root}/avatar-decorations/${userId}/${hash}`, { format, size }),
GuildMemberAvatar: (guildId, memberId, hash, format = 'webp', size, dynamic = false) => {
if (dynamic && hash.startsWith('a_')) format = 'gif';
return makeImageUrl(`${root}/guilds/${guildId}/users/${memberId}/avatars/${hash}`, { format, size });