Method: RuboCop::Cop::Lint::Eval#on_send
- Defined in:
- lib/rubocop/cop/lint/eval.rb
#on_send(node) ⇒ Object
11 12 13 14 15 16 17 18 19 |
# File 'lib/rubocop/cop/lint/eval.rb', line 11 def on_send(node) receiver, method_name, *args = *node return unless receiver.nil? && method_name == :eval && !args.empty? && args.first.type != :str add_offense(node, :selector) end |