Sha256: 7aa8ae33f4692e0d121b5f0ea92d0a25cf13b5abd4a61987e95f36bbea22857b
Contents?: true
Size: 743 Bytes
Versions: 10
Compression:
Stored size: 743 Bytes
Contents
# frozen_string_literal: true module RuboCop module Cop module Layout # This cops checks if empty lines exist around the bodies of begin-end # blocks. # # @example # # # good # # begin # # ... # end # # # bad # # begin # # # ... # # end class EmptyLinesAroundBeginBody < Cop include EmptyLinesAroundBody KIND = '`begin`'.freeze def on_kwbegin(node) check(node, nil) end def autocorrect(node) EmptyLineCorrector.correct(node) end private def style :no_empty_lines end end end end end
Version data entries
10 entries across 10 versions & 2 rubygems