]> source.dussan.org Git - redmine.git/commitdiff
Error when using views/issues/index.api.rsb in a plugin (#13924).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 27 Jun 2015 08:04:21 +0000 (08:04 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 27 Jun 2015 08:04:21 +0000 (08:04 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@14375 e93f8b46-1217-0410-a6f0-8f06a7374b81

config/initializers/10-patches.rb

index 5c2f913b00c6bed2d57f6f5d3c71feb57c73bb72..dae04fc982b057106dd31eafa4c58db0a5e94102 100644 (file)
@@ -43,7 +43,7 @@ module ActionView
   class Resolver
     def find_all(name, prefix=nil, partial=false, details={}, key=nil, locals=[])
       cached(key, [name, prefix, partial], details, locals) do
-        if details[:formats] & [:xml, :json]
+        if (details[:formats] & [:xml, :json]).any?
           details = details.dup
           details[:formats] = details[:formats].dup + [:api]
         end