From eb143b0acb466e7d146cb1a1f46dc404faf77556 Mon Sep 17 00:00:00 2001 From: ataft <11670864+ataft@users.noreply.github.com> Date: Fri, 27 Mar 2020 16:43:14 -0700 Subject: [PATCH] Update migration.js Execute alterTable statements in order --- lib/migration.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/migration.js b/lib/migration.js index ad63b27..6778526 100644 --- a/lib/migration.js +++ b/lib/migration.js @@ -340,7 +340,7 @@ function mixinMigration(MsSQL) { statements = statements.concat(self.getDropColumns(model, actualFields)); statements = statements.concat(self.addIndexes(model, actualIndexes)); - async.each(statements, function(query, fn) { + async.eachSeries(statements, function(query, fn) { if (checkOnly) { fn(null, true, {statements: statements, query: query}); } else {