Skip to content

Commit

Permalink
fix: pass correct 'transactional' parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
bevzzz committed Nov 19, 2024
1 parent 5cc961d commit ebdef1b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions migrate/auto.go
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ func (am *AutoMigrator) Migrate(ctx context.Context, opts ...MigrationOption) (*
// CreateSQLMigration writes required changes to a new migration file.
// Use migrate.Migrator to apply the generated migrations.
func (am *AutoMigrator) CreateSQLMigrations(ctx context.Context) ([]*MigrationFile, error) {
_, files, err := am.createSQLMigrations(ctx, true)
_, files, err := am.createSQLMigrations(ctx, false)
if err == errNothingToMigrate {
return files, nil
}
Expand All @@ -227,7 +227,7 @@ func (am *AutoMigrator) CreateSQLMigrations(ctx context.Context) ([]*MigrationFi
// CreateTxSQLMigration writes required changes to a new migration file making sure they will be executed
// in a transaction when applied. Use migrate.Migrator to apply the generated migrations.
func (am *AutoMigrator) CreateTxSQLMigrations(ctx context.Context) ([]*MigrationFile, error) {
_, files, err := am.createSQLMigrations(ctx, false)
_, files, err := am.createSQLMigrations(ctx, true)
if err == errNothingToMigrate {
return files, nil
}
Expand Down

0 comments on commit ebdef1b

Please sign in to comment.