Use PetState#updated_at for the supported pose cache key, not latest ID
This is because labeling poses with the Support tools *should* invalidate the `PetState.all_supported_poses` cache! But the previous cache key would only invalidate when a new pet state is *added*, not when one is *edited*.
This commit is contained in:
parent
fe67211fdf
commit
13a0362e6d
1 changed files with 1 additions and 1 deletions
|
@ -211,7 +211,7 @@ class PetState < ApplicationRecord
|
|||
end
|
||||
|
||||
def self.last_updated_key
|
||||
PetState.maximum(:id)
|
||||
PetState.maximum(:updated_at)
|
||||
end
|
||||
|
||||
def self.all_supported_poses
|
||||
|
|
Loading…
Reference in a new issue