lib/rubocop/cop/layout/multiline_block_layout.rb in rubocop-0.52.0 vs lib/rubocop/cop/layout/multiline_block_layout.rb in rubocop-0.52.1

- old
+ new

@@ -46,11 +46,11 @@ unless args_on_beginning_line?(node) add_offense_for_expression(node, node.arguments, ARG_MSG) end - return unless node.body && node.loc.begin.line == node.body.loc.line + return unless node.body && node.loc.begin.line == node.body.first_line add_offense_for_expression(node, node.body, MSG) end def autocorrect(node) @@ -62,10 +62,10 @@ return unless node.body expr_before_body ||= node.loc.begin - if expr_before_body.line == node.body.loc.line + if expr_before_body.line == node.body.first_line autocorrect_body(corrector, node, node.body) end end end