Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix cache not expire when setting maxCachePeriodInSecond to 0 #1160

Merged
merged 1 commit into from
Apr 19, 2019

Conversation

zzzzeu
Copy link
Contributor

@zzzzeu zzzzeu commented Apr 17, 2019

No description provided.

@onevcat
Copy link
Owner

onevcat commented Apr 17, 2019

As documented in the comment

Setting this to a negative value will make the disk cache never expires.

So I guess the current logic is correct. How do you think about it?

@zzzzeu
Copy link
Contributor Author

zzzzeu commented Apr 18, 2019

Setting this to a negative value will make the disk cache never expires.

That is exactly why I think it isn't quite right.
When setting maxCachePeriodInSecond to 0, the expectation was the cache expire immediately, cause 0 isn't negative, don't you think?

@onevcat
Copy link
Owner

onevcat commented Apr 19, 2019

Oh!

@onevcat onevcat merged commit 8de2f00 into onevcat:master Apr 19, 2019
skoduricg pushed a commit to rentpath/Kingfisher that referenced this pull request Sep 24, 2021
Fix cache not expire when setting maxCachePeriodInSecond to 0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants