更新代码
This commit is contained in:
@@ -46,14 +46,15 @@ class CommentPagingSource(
|
||||
postUser = postUser,
|
||||
selfNotice = selfNotice,
|
||||
order = order,
|
||||
parentCommentId = parentCommentId
|
||||
parentCommentId = parentCommentId,
|
||||
pageSize = params.loadSize
|
||||
)
|
||||
LoadResult.Page(
|
||||
data = comments.list,
|
||||
prevKey = if (currentPage == 1) null else currentPage - 1,
|
||||
nextKey = if (comments.list.isEmpty()) null else comments.page + 1
|
||||
)
|
||||
} catch (exception: IOException) {
|
||||
} catch (exception: Exception) {
|
||||
return LoadResult.Error(exception)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user