Module: ActiveRecordShards::DefaultReplicaPatches::SchemaDefinePatch
- Defined in:
- lib/active_record_shards/default_replica_patches.rb
Instance Method Summary collapse
Instance Method Details
#define(info, &block) ⇒ Object
212 213 214 215 216 217 218 |
# File 'lib/active_record_shards/default_replica_patches.rb', line 212 def define(info, &block) old_val = Thread.current._active_record_shards_in_migration Thread.current._active_record_shards_in_migration = true super ensure Thread.current._active_record_shards_in_migration = old_val end |