Set unsplash empty collection caching to one hour

This commit is contained in:
kolaente 2020-05-31 20:50:51 +02:00
parent ebfa982c72
commit 8f35b9d579
Signed by untrusted user: konrad
GPG Key ID: F40E70337AB24C9B

View File

@ -135,7 +135,7 @@ func (p *Provider) Search(search string, page int64) (result []*background.Image
var existsForPage bool var existsForPage bool
if emptySearchResult != nil && if emptySearchResult != nil &&
time.Since(emptySearchResult.lastCached) < time.Minute { time.Since(emptySearchResult.lastCached) < time.Hour {
_, existsForPage = emptySearchResult.images[page] _, existsForPage = emptySearchResult.images[page]
} }