Merge pull request #5386 from RafaelsRamos/fix/5361

fix: oldest videos repeatedly displayed when loading channel videos
This commit is contained in:
Bnyro 2023-12-26 12:02:34 +01:00 committed by GitHub
commit 7221126e1d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -116,7 +116,7 @@ class ChannelFragment : DynamicLayoutManagerFragment() {
try {
if (binding.tabChips.checkedChipId == binding.videos.id) {
fetchChannelNextPage(nextPages[0] ?: return@launch)?.let {
fetchChannelNextPage(nextPages[0] ?: return@launch).let {
nextPages[0] = it
}
} else {
@ -127,7 +127,7 @@ class ChannelFragment : DynamicLayoutManagerFragment() {
tab.name == possibleTabs[currentTabIndex - 1].identifierName
}
val nextPage = nextPages[currentTabIndex] ?: return@launch
fetchTabNextPage(nextPage, channelTab)?.let {
fetchTabNextPage(nextPage, channelTab).let {
nextPages[currentTabIndex] = it
}
}