Skip to content

Commit

Permalink
Use TemplateDetails::Requested as details_key
Browse files Browse the repository at this point in the history
  • Loading branch information
jhawthorn committed Aug 9, 2021
1 parent 6983a89 commit da81403
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion actionview/lib/action_view/lookup_context.rb
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def self.details_cache_key(details)
details = details.dup
details[:formats] &= Template::Types.symbols
end
@details_keys[details] ||= Object.new
@details_keys[details] ||= TemplateDetails::Requested.new(**details)
end

def self.clear
Expand Down
2 changes: 1 addition & 1 deletion actionview/lib/action_view/template/resolver.rb
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ def all_template_paths # :nodoc:
private
def _find_all(name, prefix, partial, details, key, locals)
path = TemplatePath.build(name, prefix, partial)
requested_details = TemplateDetails::Requested.new(**details)
requested_details = key || TemplateDetails::Requested.new(**details)
query(path, requested_details, locals, cache: !!key)
end

Expand Down

0 comments on commit da81403

Please sign in to comment.