不要怂,就是干,撸起袖子干!

Commit e60312dd by Sascha Depold

Merge pull request #403 from ricardograca/master

Only load .js files from the migrations directory
2 parents c18a7f36 c3b6e629
Showing with 4 additions and 1 deletions
......@@ -4,3 +4,4 @@ test*.js
.DS_STORE
node_modules
npm-debug.log
*~
......@@ -93,7 +93,9 @@ module.exports = (function() {
callback && callback(null, result)
}
var migrationFiles = fs.readdirSync(this.options.path)
var migrationFiles = fs.readdirSync(this.options.path).filter(function(file) {
return /\.js$/.test(file)
})
var migrations = migrationFiles.map(function(file) {
return new Migration(self, self.options.path + '/' + file)
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!