class RuboCop::Rails::SchemaLoader::AddIndex

Represent an `add_index`

Attributes

table_name[R]

Public Class Methods

new(node) click to toggle source
# File lib/rubocop/rails/schema_loader/schema.rb, line 176
def initialize(node)
  super(node)

  @table_name = node.first_argument.value
  @columns, @expression = build_columns_or_expr(node.arguments[1])
  @unique = nil

  analyze_keywords!(node)
end