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

How can I get a key for a fetch_by_some_attribute([a, b]) if the result is nil? #456

Open
SubandiK opened this issue Apr 8, 2020 · 0 comments

Comments

@SubandiK
Copy link

SubandiK commented Apr 8, 2020

So I'm running into stale data issues as per the warning in the readme.
I would like to just invalidate / not even store the result if a fetch_by_some_attribute returns nil.
Failing that, I would like to invalidate the cache by doing IdentityCache.cache.clear(some_key).
But how do I get the key from
Model.fetch_by_some_attribute(['green', 'red'])
if it returns nil?

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

No branches or pull requests

1 participant