Invalidate HTTP caching when the cards change
https://app.fizzy.do/5986089/cards/3067
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
class My::PinsController < ApplicationController
|
||||
def index
|
||||
@pins = Current.user.pins.includes(:card).ordered.limit(20)
|
||||
fresh_when @pins
|
||||
fresh_when etag: [ @pins, @pins.collect(&:card) ]
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user