mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
swiftlint fixes
This commit is contained in:
parent
caefa364a8
commit
f0034f8167
3 changed files with 3 additions and 7 deletions
|
|
@ -10,11 +10,8 @@ struct SafariWebLink: Identifiable {
|
|||
}
|
||||
|
||||
func encodeHighlightResult(_ highlight: Highlight) -> [String: Any]? {
|
||||
let data = try? JSONEncoder().encode(highlight)
|
||||
if let data = data, let dictionary = try? JSONSerialization.jsonObject(with: data, options: .allowFragments) as? [String: Any] {
|
||||
return dictionary
|
||||
}
|
||||
return nil
|
||||
guard let data = try? JSONEncoder().encode(highlight) else { return nil }
|
||||
return try? JSONSerialization.jsonObject(with: data, options: .allowFragments) as? [String: Any]
|
||||
}
|
||||
|
||||
final class WebReaderViewModel: ObservableObject {
|
||||
|
|
|
|||
|
|
@ -70,8 +70,8 @@ public struct FeedItem: Identifiable, Hashable, Decodable {
|
|||
self.labels = labels
|
||||
}
|
||||
|
||||
// swiftlint:disable:next line_length
|
||||
enum CodingKeys: String, CodingKey {
|
||||
// swiftlint:disable:next line_length
|
||||
case id, title, createdAt, savedAt, image, isArchived, readingProgressPercent, readingProgressAnchorIndex, slug, contentReader, url, labels
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -3,7 +3,6 @@ import Foundation
|
|||
import Models
|
||||
import SwiftGraphQL
|
||||
|
||||
// swiftlint:disable:next function_body_length
|
||||
public extension DataService {
|
||||
func articleContentPublisher(username: String, slug: String) -> AnyPublisher<ArticleContent, ServerError> {
|
||||
enum QueryResult {
|
||||
|
|
|
|||
Loading…
Reference in a new issue