diff options
Diffstat (limited to 'rubocop/cop/migration/add_column_with_default.rb')
-rw-r--r-- | rubocop/cop/migration/add_column_with_default.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/rubocop/cop/migration/add_column_with_default.rb b/rubocop/cop/migration/add_column_with_default.rb index afd7d93cd47..36603e09263 100644 --- a/rubocop/cop/migration/add_column_with_default.rb +++ b/rubocop/cop/migration/add_column_with_default.rb @@ -5,7 +5,7 @@ require_relative '../../migration_helpers' module RuboCop module Cop module Migration - class AddColumnWithDefault < RuboCop::Cop::Cop + class AddColumnWithDefault < RuboCop::Cop::Base include MigrationHelpers MSG = '`add_column_with_default` is deprecated, use `add_column` instead' @@ -15,7 +15,7 @@ module RuboCop name = node.children[1] - add_offense(node, location: :selector) if name == :add_column_with_default + add_offense(node.loc.selector) if name == :add_column_with_default end end end |