I would expect Fetch() to behave a little differently and not return stale items. Instead it seems like the fetch function argument is invoked only if the item is missing entirely from the cache.
Would you be open to PRs changing that behavior, or provide a FetchAndRefresh() that runs the fetch function both if the item is expired and missing?
I would expect
Fetch()
to behave a little differently and not return stale items. Instead it seems like thefetch
function argument is invoked only if the item is missing entirely from the cache. Would you be open to PRs changing that behavior, or provide aFetchAndRefresh()
that runs thefetch
function both if the item is expired and missing?Essentially this: