Sha256: 51640e32d7aaa713a9b2f40ae3f3a88ecb1698d7b3c0b1d04240f23630be6148
Contents?: true
Size: 442 Bytes
Versions: 14
Compression:
Stored size: 442 Bytes
Contents
# frozen_string_literal: true module CustomCops # This cop checks for the presence of `method_missing` # # @example # #bad # def method_missing # end # # #good # # not using method missing # class MethodMissing < RuboCop::Cop::Base MSG = 'Avoid method missing.' def on_def(node) return unless node.method?(:method_missing) add_offense(node) end alias on_defs on_def end end
Version data entries
14 entries across 14 versions & 1 rubygems