diff --git a/Sources/WordPressKit/Models/Stats/Insights/StatsLastPostInsight.swift b/Sources/WordPressKit/Models/Stats/Insights/StatsLastPostInsight.swift index c13845e0..6241a72d 100644 --- a/Sources/WordPressKit/Models/Stats/Insights/StatsLastPostInsight.swift +++ b/Sources/WordPressKit/Models/Stats/Insights/StatsLastPostInsight.swift @@ -1,4 +1,4 @@ -public struct StatsLastPostInsight: Decodable { +public struct StatsLastPostInsight: Equatable, Decodable { public let title: String public let url: URL public let publishedDate: Date diff --git a/Sources/WordPressKit/Models/Stats/Insights/StatsPostingStreakInsight.swift b/Sources/WordPressKit/Models/Stats/Insights/StatsPostingStreakInsight.swift index ec197f60..035ce31b 100644 --- a/Sources/WordPressKit/Models/Stats/Insights/StatsPostingStreakInsight.swift +++ b/Sources/WordPressKit/Models/Stats/Insights/StatsPostingStreakInsight.swift @@ -1,4 +1,4 @@ -public struct StatsPostingStreakInsight: Codable { +public struct StatsPostingStreakInsight: Equatable, Codable { public let streaks: PostingStreaks public let postingEvents: [PostingStreakEvent] @@ -54,7 +54,7 @@ public struct StatsPostingStreakInsight: Codable { } } -public struct PostingStreakEvent: Codable { +public struct PostingStreakEvent: Equatable, Codable { public let date: Date public let postCount: Int @@ -64,7 +64,7 @@ public struct PostingStreakEvent: Codable { } } -public struct PostingStreaks: Codable { +public struct PostingStreaks: Equatable, Codable { public let long: PostingStreak? public let current: PostingStreak? @@ -76,7 +76,7 @@ public struct PostingStreaks: Codable { } } -public struct PostingStreak: Codable { +public struct PostingStreak: Equatable, Codable { public let start: Date public let end: Date public let length: Int diff --git a/Sources/WordPressKit/Models/Stats/StatsPostDetails.swift b/Sources/WordPressKit/Models/Stats/StatsPostDetails.swift index 89a5e720..46d5823d 100644 --- a/Sources/WordPressKit/Models/Stats/StatsPostDetails.swift +++ b/Sources/WordPressKit/Models/Stats/StatsPostDetails.swift @@ -1,4 +1,4 @@ -public struct StatsPostDetails { +public struct StatsPostDetails: Equatable { public let fetchedDate: Date public let totalViewsCount: Int @@ -8,7 +8,7 @@ public struct StatsPostDetails { public let lastTwoWeeks: [StatsPostViews] } -public struct StatsWeeklyBreakdown { +public struct StatsWeeklyBreakdown: Equatable { public let startDay: DateComponents public let endDay: DateComponents @@ -19,7 +19,7 @@ public struct StatsWeeklyBreakdown { public let days: [StatsPostViews] } -public struct StatsPostViews { +public struct StatsPostViews: Equatable { public let period: StatsPeriodUnit public let date: DateComponents public let viewsCount: Int