mirror of
https://github.com/Athou/commafeed.git
synced 2026-03-21 21:37:29 +00:00
return the correct media type for favicons (fix #736)
This commit is contained in:
@@ -36,7 +36,7 @@ public class YoutubeFaviconFetcher extends AbstractFaviconFetcher {
|
||||
private final CommaFeedConfiguration config;
|
||||
|
||||
@Override
|
||||
public byte[] fetch(Feed feed) {
|
||||
public Favicon fetch(Feed feed) {
|
||||
String url = feed.getUrl();
|
||||
|
||||
if (!url.toLowerCase().contains("youtube.com/feeds/videos.xml")) {
|
||||
@@ -94,8 +94,8 @@ public class YoutubeFaviconFetcher extends AbstractFaviconFetcher {
|
||||
}
|
||||
|
||||
if (!isValidIconResponse(bytes, contentType)) {
|
||||
bytes = null;
|
||||
return null;
|
||||
}
|
||||
return bytes;
|
||||
return new Favicon(bytes, contentType);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user