Merge pull request #3567 from ByteHamster/prefer-image-from-feed
Prefer image that is specified in feed over embedded image
This commit is contained in:
commit
3b51af00e3
|
@ -375,10 +375,10 @@ public class FeedItem extends FeedComponent implements ShownotesProvider, ImageR
|
|||
|
||||
@Override
|
||||
public String getImageLocation() {
|
||||
if(media != null && media.hasEmbeddedPicture()) {
|
||||
return media.getImageLocation();
|
||||
} else if (imageUrl != null) {
|
||||
return imageUrl;
|
||||
if (imageUrl != null) {
|
||||
return imageUrl;
|
||||
} else if (media != null && media.hasEmbeddedPicture()) {
|
||||
return media.getLocalMediaUrl();
|
||||
} else if (feed != null) {
|
||||
return feed.getImageLocation();
|
||||
} else {
|
||||
|
|
|
@ -566,10 +566,10 @@ public class FeedMedia extends FeedFile implements Playable {
|
|||
|
||||
@Override
|
||||
public String getImageLocation() {
|
||||
if (hasEmbeddedPicture()) {
|
||||
return getLocalMediaUrl();
|
||||
} else if(item != null) {
|
||||
if (item != null) {
|
||||
return item.getImageLocation();
|
||||
} else if (hasEmbeddedPicture()) {
|
||||
return getLocalMediaUrl();
|
||||
} else {
|
||||
return null;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue