From ab2b47d8e591e9a0da3a183737923c81fce4b4c3 Mon Sep 17 00:00:00 2001 From: Sam Bauers Date: Wed, 30 Apr 2014 15:27:58 +1000 Subject: [PATCH] Fix ETags to include cache_key and locale only. --- lib/locomotive/render.rb | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/lib/locomotive/render.rb b/lib/locomotive/render.rb index fa5d9ed64d..2ca63d41af 100644 --- a/lib/locomotive/render.rb +++ b/lib/locomotive/render.rb @@ -67,11 +67,8 @@ def prepare_and_set_response(output) # Inputs which define the ETag for this response etag_inputs = { - 'page' => @page, - 'params' => { - 'page_path' => params[:page_path], - 'locale' => params[:locale] - } + 'page' => @page.cache_key, + 'locale' => params[:locale] } if @page.with_cache?