Skip to content

Commit

Permalink
fix: wrong isLoading state
Browse files Browse the repository at this point in the history
  • Loading branch information
haowenwu committed Jun 11, 2024
1 parent 4e8d53d commit d2c9b38
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,12 @@ class FeedCollectionViewController: UIViewController {
}

func appendData(displayData: [any DisplayData]) {
isLoading = false
_displayData.append(contentsOf: displayData.map { AnyDispplayData(data: $0) }.filter({ !_displayData.contains($0) }))
if displayData.count < pageSize - 5 || displayData.count == 0 {
finished = true
return
}
isLoading = false

if _displayData.count < 12 {
isLoading = true
Expand Down

0 comments on commit d2c9b38

Please # to comment.