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

Set created_at as collection cache key #295

Merged
merged 1 commit into from
Sep 20, 2016
Merged

Set created_at as collection cache key #295

merged 1 commit into from
Sep 20, 2016

Conversation

bmedenwald
Copy link
Contributor

With Rails Conditional GET support (304 caching), the stale? and fresh_when methods rely on collection_cache_key, which by default utilize the updated_at column. Because the audits table doesn't include an updated_at column, this throws an SQL error.

This change simply changed the default and relies on super.

@danielmorrison danielmorrison merged commit 1091160 into collectiveidea:master Sep 20, 2016
@jaredbeck
Copy link
Contributor

Would a better title for this PR be "SQL error in Rails Conditional GET (304 caching)"? Might help searchers in the future.

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.

3 participants