readrops / Readrops

Android multi-services RSS client
GNU General Public License v3.0
251 stars 19 forks source link

Fix error in case that Nextcloud News item does not have a body element #164

Open mbyrenh opened 1 year ago

mbyrenh commented 1 year ago

When using Readrops to fetch news items from Nextcloud 24.0.6 with News Plugin 18.2.0, it is possible that a news item may not contain a "body" element. In this case, the "content" member of the corresponding item instance will be null, causing the computation of the read time during the initial sync to fail. The change in this pull request causes Readrops to use the description property of the corresponding item instead if it is available or just leaving the default value of 0.0 for the read time if neither the content nor the description is set.

mbyrenh commented 1 year ago

The force push was done to remove the commit for which I created a separate pull request from this pull request.