Prevent saved items from being deleted
This commit is contained in:
parent
57e2176e03
commit
595b135316
@ -61,7 +61,7 @@ func (fs *FeedStore) DeleteOldReadItems() {
|
|||||||
t := time.Now()
|
t := time.Now()
|
||||||
threshold := t.Add(-time.Hour * 24 * 7)
|
threshold := t.Add(-time.Hour * 24 * 7)
|
||||||
fs.getDB().Table("items").
|
fs.getDB().Table("items").
|
||||||
Where("read = ? and created < ?", true, threshold).
|
Where("save = ? and read = ? and created < ?", false, true, threshold).
|
||||||
Delete(Item{})
|
Delete(Item{})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user