From f1b1c2f4712e089d9a00310f24d54c672f707235 Mon Sep 17 00:00:00 2001 From: Go MAEDA Date: Thu, 1 Apr 2021 14:46:15 +0000 Subject: [PATCH] Fix Subclasses must implement a find_templates(name, prefix, partial, details, locals = []) method (#29914). Patch by Go MAEDA. git-svn-id: http://svn.redmine.org/redmine/trunk@20883 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- config/initializers/10-patches.rb | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/config/initializers/10-patches.rb b/config/initializers/10-patches.rb index 9af59563e..cc6113d48 100644 --- a/config/initializers/10-patches.rb +++ b/config/initializers/10-patches.rb @@ -53,12 +53,14 @@ module ActionView class Resolver def find_all(name, prefix=nil, partial=false, details={}, key=nil, locals=[]) + locals = locals.map(&:to_s).sort!.freeze + cached(key, [name, prefix, partial], details, locals) do if (details[:formats] & [:xml, :json]).any? details = details.dup details[:formats] = details[:formats].dup + [:api] end - find_templates(name, prefix, partial, details) + _find_all(name, prefix, partial, details, key, locals) end end end -- 2.39.5