summaryrefslogtreecommitdiff
path: root/Sora
diff options
context:
space:
mode:
authorFuwn <[email protected]>2025-09-11 22:38:48 -0700
committerFuwn <[email protected]>2025-09-11 22:38:48 -0700
commit16682d6fac87a07ec81c54f375ac6a5cd621dea9 (patch)
tree57ea9f02dfd8db076ad98d0cbc06493ea54de7dd /Sora
parentfeat: Development commit (diff)
downloadsora-testing-16682d6fac87a07ec81c54f375ac6a5cd621dea9.tar.xz
sora-testing-16682d6fac87a07ec81c54f375ac6a5cd621dea9.zip
feat: Development commit
Diffstat (limited to 'Sora')
-rw-r--r--Sora/Views/Post/Details/Carousel/PostDetailsCarouselView.swift2
-rw-r--r--Sora/Views/Post/Grid/PostGridView.swift6
2 files changed, 4 insertions, 4 deletions
diff --git a/Sora/Views/Post/Details/Carousel/PostDetailsCarouselView.swift b/Sora/Views/Post/Details/Carousel/PostDetailsCarouselView.swift
index 85208ca..94d258e 100644
--- a/Sora/Views/Post/Details/Carousel/PostDetailsCarouselView.swift
+++ b/Sora/Views/Post/Details/Carousel/PostDetailsCarouselView.swift
@@ -67,8 +67,6 @@ struct PostDetailsCarouselView: View {
if currentIndex == posts.count - 1 { await manager.loadNextPage() }
}
- manager.selectedPost = posts[currentIndex]
-
preloadNearbyImages()
}
.onAppear(perform: preloadNearbyImages)
diff --git a/Sora/Views/Post/Grid/PostGridView.swift b/Sora/Views/Post/Grid/PostGridView.swift
index 025c3d2..5c071b8 100644
--- a/Sora/Views/Post/Grid/PostGridView.swift
+++ b/Sora/Views/Post/Grid/PostGridView.swift
@@ -253,11 +253,13 @@ struct PostGridView: View { // swiftlint:disable:this type_body_length
await performLocalSearch()
}
} else {
- let currentTags = localSearchText.components(separatedBy: .whitespaces).filter { !$0.isEmpty }
+ let currentTags = localSearchText.components(separatedBy: .whitespaces).filter { tag in
+ !tag.isEmpty
+ }
let hasPosts = !localPosts.isEmpty
let initialTags = initialTag.components(separatedBy: .whitespaces).filter { !$0.isEmpty }
let needsFetch = !hasPosts || currentTags != initialTags
-
+
if needsFetch {
currentLocalTask = Task(priority: .userInitiated) {
await fetchLocalPosts(