aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--internal/feed/cache_v1.go6
1 files changed, 4 insertions, 2 deletions
diff --git a/internal/feed/cache_v1.go b/internal/feed/cache_v1.go
index b5d6b3e..656c133 100644
--- a/internal/feed/cache_v1.go
+++ b/internal/feed/cache_v1.go
@@ -85,8 +85,10 @@ func (cf *cachedFeed) Checked(withFailure bool) {
}
func (cf *cachedFeed) Commit() {
- cf.Items = cf.newItems
- cf.newItems = nil
+ if cf.newItems != nil {
+ cf.Items = cf.newItems
+ cf.newItems = nil
+ }
cf.LastCheck = cf.currentCheck
}