On remet les images.
This commit is contained in:
File diff suppressed because one or more lines are too long
@@ -609,11 +609,10 @@ impl ToXmlElement for Item {
|
||||
elem.children
|
||||
.push(XMLNode::Element(text_element("upnp:genre", genre)));
|
||||
}
|
||||
// NOTE: albumArtURI temporarily disabled for compatibility (some CPs misbehave)
|
||||
// if let Some(ref art) = self.album_art {
|
||||
// elem.children
|
||||
// .push(XMLNode::Element(text_element("upnp:albumArtURI", art)));
|
||||
// }
|
||||
if let Some(ref art) = self.album_art {
|
||||
elem.children
|
||||
.push(XMLNode::Element(text_element("upnp:albumArtURI", art)));
|
||||
}
|
||||
if let Some(date) = self.normalized_date() {
|
||||
elem.children
|
||||
.push(XMLNode::Element(text_element("dc:date", &date)));
|
||||
|
||||
@@ -318,6 +318,15 @@ impl RadioParadiseSource {
|
||||
if item.genre.is_none() {
|
||||
item.genre = Some("Radio Paradise".to_string());
|
||||
}
|
||||
|
||||
// Normaliser l'albumArtURI : rendre absolu si chemin relatif, sinon fallback par défaut
|
||||
if let Some(art) = item.album_art.as_mut() {
|
||||
if art.starts_with('/') {
|
||||
*art = format!("{}{}", self.base_url, art);
|
||||
}
|
||||
} else {
|
||||
item.album_art = Some(self.default_cover_url());
|
||||
}
|
||||
}
|
||||
|
||||
Ok(items)
|
||||
|
||||
Reference in New Issue
Block a user