|
|
@@ -72,11 +72,12 @@ extension LNProfileFeedProvider: LNFeedManagerNotify {
|
|
|
guard let res else { return }
|
|
|
|
|
|
let curFirst = feedList.first?.id ?? ""
|
|
|
- guard let index = res.list.firstIndex(where: { $0.id == curFirst }) else {
|
|
|
- return
|
|
|
+ if let index = res.list.firstIndex(where: { $0.id == curFirst }) {
|
|
|
+ let newItems = res.list[..<index]
|
|
|
+ feedList.insert(contentsOf: newItems, at: 0)
|
|
|
+ } else {
|
|
|
+ feedList.insert(contentsOf: res.list, at: 0)
|
|
|
}
|
|
|
- let newItems = res.list[..<index]
|
|
|
- feedList.insert(contentsOf: newItems, at: 0)
|
|
|
tableView?.reloadData()
|
|
|
}
|
|
|
}
|