Update streaming_template_renderer.rb
Remove extra `layout_name` check. At that point in the time layout_time will be defined so there's no need to check for it once again.
This commit is contained in:
parent
c388a4dcf5
commit
adf80fe807
@ -46,7 +46,7 @@ def render_template(view, template, layout_name = nil, locals = {}) # :nodoc:
|
||||
return [super.body] unless layout_name && template.supports_streaming?
|
||||
|
||||
locals ||= {}
|
||||
layout = layout_name && find_layout(layout_name, locals.keys, [formats.first])
|
||||
layout = find_layout(layout_name, locals.keys, [formats.first])
|
||||
|
||||
Body.new do |buffer|
|
||||
delayed_render(buffer, template, layout, view, locals)
|
||||
|
Loading…
Reference in New Issue
Block a user