lib/nanoc/helpers/rendering.rb in nanoc-4.4.1 vs lib/nanoc/helpers/rendering.rb in nanoc-4.4.2

- old
+ new

@@ -45,31 +45,23 @@ raise Nanoc::Int::Errors::UnknownFilter.new(filter_name) if filter_class.nil? # Create filter filter = filter_class.new(assigns) - begin - # Notify start - Nanoc::Int::NotificationCenter.post(:processing_started, layout) + # Layout + content = layout.content + arg = content.binary? ? content.filename : content.string + result = filter.setup_and_run(arg, filter_args) - # Layout - content = layout.content - arg = content.binary? ? content.filename : content.string - result = filter.setup_and_run(arg, filter_args) - - # Append to erbout if we have a block - if block_given? - # Append result and return nothing - erbout = eval('_erbout', block.binding) - erbout << result - '' - else - # Return result - result - end - ensure - # Notify end - Nanoc::Int::NotificationCenter.post(:processing_ended, layout) + # Append to erbout if we have a block + if block_given? + # Append result and return nothing + erbout = eval('_erbout', block.binding) + erbout << result + '' + else + # Return result + result end end end end