lib/asciidoctor/abstract_block.rb in asciidoctor-2.0.15 vs lib/asciidoctor/abstract_block.rb in asciidoctor-2.0.16

- old
+ new

@@ -88,11 +88,11 @@ # # This method changes the context of this block. It also updates the node name accordingly. # # context - the context Symbol context to assign to this block # - # Returns the new context Symbol assigned to this block + # Returns the specified Symbol context def context= context @node_name = (@context = context).to_s end # Public: Append a content block to this block's list of blocks. @@ -294,11 +294,11 @@ @title ? true : false end # Public: Set the String block title. # - # Returns the new String title assigned to this Block + # Returns the specified String title def title= val @converted_title = nil @title = val end @@ -478,11 +478,11 @@ # process document header as a section, if present if header? && (any_context || context_selector == :section) @header.find_by_internal selector, result, &block end @blocks.each do |b| - next if (context_selector == :section && b.context != :section) # optimization + next if context_selector == :section && b.context != :section # optimization b.find_by_internal selector, result, &block end end when :dlist # dlist has different structure than other blocks @@ -503,10 +503,10 @@ else (rows.head + rows.body + rows.foot).each {|r| r.each {|c| c.find_by_internal selector, result, &block } } end else @blocks.each do |b| - next if (context_selector == :section && b.context != :section) # optimization + next if context_selector == :section && b.context != :section # optimization b.find_by_internal selector, result, &block end end result end