Use description for shownotes if it is longer than contentEncoded
This commit is contained in:
parent
afb9f7db6a
commit
5048eb10d2
|
@ -373,7 +373,17 @@ public class FeedItem extends FeedComponent implements ShownotesProvider, Flattr
|
||||||
if (contentEncoded == null || description == null) {
|
if (contentEncoded == null || description == null) {
|
||||||
DBReader.loadExtraInformationOfFeedItem(FeedItem.this);
|
DBReader.loadExtraInformationOfFeedItem(FeedItem.this);
|
||||||
}
|
}
|
||||||
return (!TextUtils.isEmpty(contentEncoded)) ? contentEncoded : description;
|
if (TextUtils.isEmpty(contentEncoded)) {
|
||||||
|
return description;
|
||||||
|
} else if (TextUtils.isEmpty(description)) {
|
||||||
|
return contentEncoded;
|
||||||
|
} else {
|
||||||
|
if (description.length() > 1.25 * contentEncoded.length()) {
|
||||||
|
return description;
|
||||||
|
} else {
|
||||||
|
return contentEncoded;
|
||||||
|
}
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue