lib/strong_migrations/migrator.rb in strong_migrations-2.0.2 vs lib/strong_migrations/migrator.rb in strong_migrations-2.1.0

- old
+ new

@@ -4,14 +4,16 @@ return super unless StrongMigrations.lock_timeout_retries > 0 && use_transaction?(migration) # handle MigrationProxy class migration = migration.send(:migration) if migration.respond_to?(:migration, true) - # retry migration since the entire transaction needs to be rerun checker = migration.send(:strong_migrations_checker) + return super if checker.skip? + + # retry migration since the entire transaction needs to be rerun checker.retry_lock_timeouts(check_committed: true) do # failed transaction reverts timeout, so need to re-apply - checker.timeouts_set = false + checker.reset super(migration, ...) end end end