details: review: Move nextPageUrl variable to function

This is only used pager, no need to expose to the class

Signed-off-by: Aayush Gupta <aayushgupta219@gmail.com>
This commit is contained in:
Aayush Gupta
2025-06-27 13:41:26 +08:00
parent 154d468322
commit d9267c7c3b

View File

@@ -37,7 +37,6 @@ class DetailsReviewViewModel @AssistedInject constructor(
private val TAG = DetailsReviewViewModel::class.java.simpleName
private var reviewsNextPageUrl: String? = null
private val _reviews = MutableStateFlow<PagingData<Review>>(PagingData.empty())
val reviews = _reviews.asStateFlow()
@@ -46,7 +45,7 @@ class DetailsReviewViewModel @AssistedInject constructor(
}
fun fetchReviews(filter: Review.Filter = Review.Filter.ALL) {
reviewsNextPageUrl = null
var reviewsNextPageUrl: String? = null
createPager { page ->
try {