From 612a0204035acabdf668f14a65ea3d0c08adcbdc Mon Sep 17 00:00:00 2001 From: "Jose Fernandez (magec)" Date: Thu, 22 Sep 2016 15:10:59 +0200 Subject: [PATCH] simpler code --- lib/rubocop/cop/migrations/remove_index.rb | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/rubocop/cop/migrations/remove_index.rb b/lib/rubocop/cop/migrations/remove_index.rb index 1bbab1e..3d9c158 100644 --- a/lib/rubocop/cop/migrations/remove_index.rb +++ b/lib/rubocop/cop/migrations/remove_index.rb @@ -12,9 +12,7 @@ module Migrations class RemoveIndex < Cop MSG = 'remove_index is disalowed'.freeze - def_node_matcher :remove_index_found, <<-PATTERN - (:send _ :remove_index ...) - PATTERN + def_node_matcher :remove_index_found, '(:send _ :remove_index ...)' def on_send(node) remove_index_found(node) do