summaryrefslogtreecommitdiff
path: root/Sora/Data/PostWithContext.swift
diff options
context:
space:
mode:
authorFuwn <[email protected]>2025-08-28 15:23:28 -0700
committerFuwn <[email protected]>2025-08-28 15:23:28 -0700
commitd7af80d2d1edcc45c043bb237c098c4cb0c026fa (patch)
treec9775296945ce4b38e611d59e586000675f3d44c /Sora/Data/PostWithContext.swift
parentfeat: Development commit (diff)
downloadsora-testing-d7af80d2d1edcc45c043bb237c098c4cb0c026fa.tar.xz
sora-testing-d7af80d2d1edcc45c043bb237c098c4cb0c026fa.zip
feat: Development commit
Diffstat (limited to 'Sora/Data/PostWithContext.swift')
-rw-r--r--Sora/Data/PostWithContext.swift8
1 files changed, 2 insertions, 6 deletions
diff --git a/Sora/Data/PostWithContext.swift b/Sora/Data/PostWithContext.swift
index c8cb2f6..b98a191 100644
--- a/Sora/Data/PostWithContext.swift
+++ b/Sora/Data/PostWithContext.swift
@@ -2,18 +2,14 @@ import Foundation
struct PostWithContext: Hashable {
let post: BooruPost
+ // swiftlint:disable:next discouraged_optional_collection
let posts: [BooruPost]?
- init(post: BooruPost, posts: [BooruPost]?) {
- self.post = post
- self.posts = posts
- }
-
func hash(into hasher: inout Hasher) {
hasher.combine(post.id)
}
- static func == (lhs: PostWithContext, rhs: PostWithContext) -> Bool {
+ static func == (lhs: Self, rhs: Self) -> Bool {
lhs.post.id == rhs.post.id
}
}