Skip to content

Commit

Permalink
fix(createMigrationsTable): create schema
Browse files Browse the repository at this point in the history
Create schema for migrations table before creation of migrations table
if the schema not exists

Signed-off-by: Alexander Maslov <alex@maslov.dev>
  • Loading branch information
drakmail committed Apr 9, 2020
1 parent 42e289b commit 328407f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,12 @@ var PgDriver = Base.extend({
return this.all('SET search_path TO ' + searchPath);
}.bind(this)
)
.then(
function () {
// create schema if not exists
return this.all('CREATE SCHEMA IF NOT EXISTS ' + searchPath);
}.bind(this)
)
.then(
function () {
return this.all(
Expand Down

0 comments on commit 328407f

Please sign in to comment.