From b881d2fed6b11f239a380e687a448d8ca69dbad5 Mon Sep 17 00:00:00 2001 From: Brent Simmons Date: Sun, 1 Dec 2024 16:54:28 -0800 Subject: [PATCH] Add cacheControlInfo to feed metadata. --- Account/Sources/Account/DataExtensions.swift | 1 + Account/Sources/Account/WebFeedMetadata.swift | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/Account/Sources/Account/DataExtensions.swift b/Account/Sources/Account/DataExtensions.swift index 61ddc93cd..eeddab039 100644 --- a/Account/Sources/Account/DataExtensions.swift +++ b/Account/Sources/Account/DataExtensions.swift @@ -27,6 +27,7 @@ public extension WebFeed { public static let authors = "authors" public static let contentHash = "contentHash" public static let conditionalGetInfo = "conditionalGetInfo" + public static let cacheControlInfo = "cacheControlInfo" } } diff --git a/Account/Sources/Account/WebFeedMetadata.swift b/Account/Sources/Account/WebFeedMetadata.swift index 924472089..037890548 100644 --- a/Account/Sources/Account/WebFeedMetadata.swift +++ b/Account/Sources/Account/WebFeedMetadata.swift @@ -27,6 +27,7 @@ final class WebFeedMetadata: Codable { case isNotifyAboutNewArticles case isArticleExtractorAlwaysOn case conditionalGetInfo + case cacheControlInfo case externalID = "subscriptionID" case folderRelationship } @@ -111,6 +112,14 @@ final class WebFeedMetadata: Codable { } } + var cacheControlInfo: CacheControlInfo? { + didSet { + if cacheControlInfo != oldValue { + valueDidChange(.cacheControlInfo) + } + } + } + var externalID: String? { didSet { if externalID != oldValue {