lib/nanoc/helpers/rendering.rb in nanoc-3.7.4 vs lib/nanoc/helpers/rendering.rb in nanoc-3.7.5

- old
+ new

@@ -1,12 +1,10 @@ # encoding: utf-8 module Nanoc::Helpers - # Provides functionality for rendering layouts as partials. module Rendering - include Nanoc::Helpers::Capturing # Renders the given layout. The given layout will be run through the first # matching layout rule. # @@ -89,18 +87,18 @@ # Capture content, if any captured_content = block_given? ? capture(&block) : nil # Get assigns assigns = { - :content => captured_content, - :item => @item, - :item_rep => @item_rep, - :items => @items, - :layout => layout, - :layouts => @layouts, - :config => @config, - :site => @site + content: captured_content, + item: @item, + item_rep: @item_rep, + items: @items, + layout: layout, + layouts: @layouts, + config: @config, + site: @site }.merge(other_assigns) # Get filter name filter_name, filter_args = @site.compiler.rules_collection.filter_for_layout(layout) raise Nanoc::Errors::CannotDetermineFilter.new(layout.identifier) if filter_name.nil? @@ -132,9 +130,7 @@ ensure # Notify end Nanoc::NotificationCenter.post(:processing_ended, layout) end end - end - end