提交 9a0e4437 编写于 作者: J Jeremy Kemper

Everything responds to #to_param

上级 8d24a029
......@@ -29,10 +29,8 @@ def self.expand_cache_key(key, namespace = nil)
key.cache_key
when key.is_a?(Array)
key.collect { |element| expand_cache_key(element) }.to_param
when key.respond_to?(:to_param)
when key
key.to_param
else
key
end.to_s
expanded_cache_key
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册