Channels search, add SDWebImage framework

This commit is contained in:
Arkadiusz Fal
2021-10-22 01:29:10 +02:00
parent bb8a8dee05
commit 0e54cbcad0
35 changed files with 859 additions and 431 deletions

View File

@@ -13,9 +13,11 @@ final class RecentsModel: ObservableObject {
}
func add(_ item: RecentItem) {
if !items.contains(where: { $0.id == item.id }) {
items.append(item)
if let index = items.firstIndex(where: { $0.id == item.id }) {
items.remove(at: index)
}
items.append(item)
}
func close(_ item: RecentItem) {