aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAustin Hellyer <[email protected]>2017-01-08 20:25:04 -0800
committerAustin Hellyer <[email protected]>2017-01-08 20:25:04 -0800
commit02a16585b0348156cd39d51c7ff75bd8162aec47 (patch)
tree43e57d09029dae8073094838e4c148b6ec1c01b0 /src
parentAdd User::default_avatar_url() method (diff)
downloadserenity-02a16585b0348156cd39d51c7ff75bd8162aec47.tar.xz
serenity-02a16585b0348156cd39d51c7ff75bd8162aec47.zip
Update icons/splashes to be WEBP
Diffstat (limited to 'src')
-rw-r--r--src/model/channel.rs2
-rw-r--r--src/model/guild.rs12
2 files changed, 7 insertions, 7 deletions
diff --git a/src/model/channel.rs b/src/model/channel.rs
index 27fac25..e9d60a8 100644
--- a/src/model/channel.rs
+++ b/src/model/channel.rs
@@ -381,7 +381,7 @@ impl Group {
/// Returns the formatted URI of the group's icon if one exists.
pub fn icon_url(&self) -> Option<String> {
self.icon.as_ref().map(|icon|
- format!(cdn!("/channel-icons/{}/{}.jpg"), self.channel_id, icon))
+ format!(cdn!("/channel-icons/{}/{}.webp"), self.channel_id, icon))
}
/// Leaves the group.
diff --git a/src/model/guild.rs b/src/model/guild.rs
index 322743e..ba0f99c 100644
--- a/src/model/guild.rs
+++ b/src/model/guild.rs
@@ -133,7 +133,7 @@ impl GuildInfo {
/// Returns the formatted URL of the guild's icon, if the guild has an icon.
pub fn icon_url(&self) -> Option<String> {
self.icon.as_ref().map(|icon|
- format!(cdn!("/icons/{}/{}.jpg"), self.id, icon))
+ format!(cdn!("/icons/{}/{}.webp"), self.id, icon))
}
}
@@ -142,7 +142,7 @@ impl InviteGuild {
#[cfg(feature="methods")]
pub fn splash_url(&self) -> Option<String> {
self.icon.as_ref().map(|icon|
- format!(cdn!("/splashes/{}/{}.jpg"), self.id, icon))
+ format!(cdn!("/splashes/{}/{}.webp"), self.id, icon))
}
}
@@ -169,7 +169,7 @@ impl PartialGuild {
/// Returns a formatted URL of the guild's icon, if the guild has an icon.
pub fn icon_url(&self) -> Option<String> {
self.icon.as_ref().map(|icon|
- format!(cdn!("/icons/{}/{}.jpg"), self.id, icon))
+ format!(cdn!("/icons/{}/{}.webp"), self.id, icon))
}
/// Performs a search request to the API for the guild's [`Message`]s.
@@ -253,7 +253,7 @@ impl PartialGuild {
#[cfg(feature="methods")]
pub fn splash_url(&self) -> Option<String> {
self.icon.as_ref().map(|icon|
- format!(cdn!("/splashes/{}/{}.jpg"), self.id, icon))
+ format!(cdn!("/splashes/{}/{}.webp"), self.id, icon))
}
/// Retrieves the guild's webhooks.
@@ -661,7 +661,7 @@ impl Guild {
/// Returns the formatted URL of the guild's icon, if one exists.
pub fn icon_url(&self) -> Option<String> {
self.icon.as_ref().map(|icon|
- format!(cdn!("/icons/{}/{}.jpg"), self.id, icon))
+ format!(cdn!("/icons/{}/{}.webp"), self.id, icon))
}
/// Checks if the guild is 'large'. A guild is considered large if it has
@@ -907,7 +907,7 @@ impl Guild {
#[cfg(feature="methods")]
pub fn splash_url(&self) -> Option<String> {
self.icon.as_ref().map(|icon|
- format!(cdn!("/splashes/{}/{}.jpg"), self.id, icon))
+ format!(cdn!("/splashes/{}/{}.webp"), self.id, icon))
}
/// Starts a prune of [`Member`]s.