Skip to content

driver.close does not call the provided callback #19

@ornoone

Description

@ornoone

a difference between your driver and others is that no callback is ever caller after all migrations is applied:

DBMigrate.getInstance(true,{})
    .sync()
    .then(() =>console.log('migration done'))
    .catch((err) => console.log('migration failed', err))

will never have his then or catch called

I found that the source of this problem is that you never call the provided callback during driver.close(cb);

this callback is responsible for terminating the promise of all operations. (see db-migrate/lib/commands/on-complete.js:11)

do you still maintains this repository, and if so, would you merge a PR that fix this bug if I fill one ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions