Sha256: 1f924bf0e76e10111304faacbcec33ac5f1bf94f9ad8fe822812f6f590b91741
Contents?: true
Size: 765 Bytes
Versions: 23
Compression:
Stored size: 765 Bytes
Contents
require 'active_record/connection_adapters/abstract/schema_statements' module Ridgepole module SchemaStatementsExt def index_name_exists?(table_name, column_name, options = {}) if Ridgepole::ExecuteExpander.noop caller_methods = caller.map {|i| i =~ /:\d+:in `(.+)'/ ? $1 : '' } if caller_methods.any? {|i| i =~ /\Aremove_index/ } true elsif caller_methods.any? {|i| i =~ /\Aadd_index/ } false else super end else super end end def rename_table_indexes(table_name, new_name) # Nothing to do end end end module ActiveRecord module ConnectionAdapters class AbstractAdapter prepend Ridgepole::SchemaStatementsExt end end end
Version data entries
23 entries across 23 versions & 1 rubygems
Version | Path |
---|---|
ridgepole-0.6.4.beta9 | lib/ridgepole/schema_statements_ext.rb |
ridgepole-0.6.4.beta8 | lib/ridgepole/schema_statements_ext.rb |
ridgepole-0.6.4.beta7 | lib/ridgepole/schema_statements_ext.rb |