From 49e89d0f85f17d8c3fab6058df8c59200116cc9c Mon Sep 17 00:00:00 2001 From: Jacques Distler Date: Tue, 26 Jan 2010 13:50:43 -0600 Subject: [PATCH] Fix Caching Fix the caching of pages with "." in their names. This was busted. --- lib/caching_stuff.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/caching_stuff.rb b/lib/caching_stuff.rb index 54634a47..fc7750eb 100644 --- a/lib/caching_stuff.rb +++ b/lib/caching_stuff.rb @@ -8,7 +8,7 @@ module CachingStuff module Caching module Fragments def fragment_cache_key(key) - ActiveSupport::Cache.expand_cache_key(key.is_a?(Hash) ? url_for(key.merge(:host=>"")).split(":///").last : key.split('/')[1..-1].join('/'), :views) + ActiveSupport::Cache.expand_cache_key(key.is_a?(Hash) ? url_for(key.merge(:host=>"")).split(":///").last : key.split('/')[1..-1].join('/').gsub(/\?format=.*/,''), :views) end end end