lib/yard/templates/section.rb in yard-0.9.25 vs lib/yard/templates/section.rb in yard-0.9.26

- old
+ new

@@ -18,12 +18,10 @@ obj end def [](*args) if args.first.is_a?(Range) || args.size > 1 - obj = super(*args) - obj.name = name - return obj + return self.class.new(name, *super(*args)) elsif args.first.is_a?(Integer) return super(*args) end find {|o| o.name == args.first } end