Skip to content

Commit

Permalink
[Hotfix] Show snippet of feed instead of "Found nothing to fetch"
Browse files Browse the repository at this point in the history
For feed if for some reason cache was cleared
  • Loading branch information
asl97 authored and spacecowboy committed Dec 16, 2024
1 parent a58105d commit 3400902
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -881,6 +881,7 @@ data class Article(
val link: String? = item?.link
val feedDisplayTitle: String = item?.feedDisplayTitle ?: ""
val title: String = item?.plainTitle ?: ""
val snippet: String = item?.plainSnippet ?: ""
val enclosure: Enclosure =
item?.enclosureLink?.let { link ->
Enclosure(
Original file line number Diff line number Diff line change
@@ -206,8 +206,8 @@ class ArticleViewModel(
}
} else {
Log.e(LOG_TAG, "No default file to parse")
textToDisplay.update { TextToDisplay.FAILED_MISSING_BODY }
LinearArticle(elements = emptyList())
textToDisplay.update { TextToDisplay.CONTENT }
htmlLinearizer.linearize(article.snippet, article.feedUrl ?: "")
}
}

0 comments on commit 3400902

Please sign in to comment.