Comments (4)
@rosesonfire a quickie here:
....
return migrator.run('up')
.then(successfulMigration => {
resolve(successfulMigration);
})
.catch(err => {
if (err.toString() === "Error: There are no migrations to run") {
console.warn("There are no migrations to run");
resolve();
} else {
reject(err);
}
});
or same thing using async/await + try/catch.
But yes this definitely should NOT be an throw Error()
, but a warning
from migrate-mongoose.
Looks great! But I don't want to write up a js script for this. I just want to use the migrate
CLI. Yes, this should be a warning, not an error. Or whether it should throw an error or a warning should be configurable.
from migrate-mongoose.
@rosesonfire agreed. @balmasi will you take a look at the PR if I submit one? cuz I see there's bunch of pending PRs and I'm not sure if you're still willing to maintain the repo.
from migrate-mongoose.
Released in 4.0.0
I appreciate bringing this to my attention!
from migrate-mongoose.
Related Issues (20)
- New Server Discover and Monitoring engine for MongoClient HOT 2
- Cannot find module '@/enums/roles'
- Use NPX instead of referencing the node module
- Ability to specify migrations for a given NODE_ENV, or support seeding for local versus migrations for production
- Microservice environment
- Are ES6 imports supported in 4.0.0? HOT 2
- Deprecation warning HOT 1
- Support Migration files with *.ts extension HOT 4
- Is this repo still maintained? HOT 4
- How do we setup migrate.json HOT 1
- I am getting "Cannot use import statement outside a module" HOT 4
- can i use migrate-mongoose in midway framework?
- up never get's past "Synchronizing database with file system migrations" HOT 1
- Unexpected token { when using the package in typescript project
- Is there a way to grab the `connectionUri` or any other useful information in the `up` or `down` functions?
- Schema hasn't been registered HOT 1
- Security vulnerability on dangling dependency of yargs "^4.8.1"
- Compromised colors package HOT 1
- Engine warning and timeout HOT 6
- Generate initial migrations?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from migrate-mongoose.