diff --git a/lib/mobylette/resolvers/chained_fallback_resolver.rb b/lib/mobylette/resolvers/chained_fallback_resolver.rb index 24cca05..ec6f870 100644 --- a/lib/mobylette/resolvers/chained_fallback_resolver.rb +++ b/lib/mobylette/resolvers/chained_fallback_resolver.rb @@ -24,9 +24,9 @@ def initialize(formats = {}, view_paths = ['app/views']) # ... # } # - # It will add the fallback chain array of the + # It will add the fallback chain array of the # request.format to the resolver. - # + # # If the format.request is not defined in formats, # it will behave as a normal FileSystemResovler. # @@ -39,12 +39,13 @@ def replace_fallback_formats_chain(formats) # Private: finds the right template on the filesystem, # using fallback if needed # - def find_templates(name, prefix, partial, details) + def find_templates(name, prefix, partial, details, outside_app_allowed = false) # checks if the format has a fallback chain if @fallback_formats.has_key?(details[:formats].first) details = details.dup - details[:formats] = Array.wrap(@fallback_formats[details[:formats].first]) + details[:formats] = Array.wrap(@fallback_formats[details[:formats].first]) end + # Skip fifth argument for compatability with older Rails version super(name, prefix, partial, details) end