Open nondefyde opened 6 years ago
I got the same problem with the Elasticsearch module v14.0. Rolling back to elasticsearch@13.2
solved the problem. The plugin needs a little update
Fixed in #38 This problem was with mongoose 5.0.0, not elasticsearch.
TypeError: _Promise is not a constructor at Object.module.exports.run (C:.....\node_modules\mongoose-elasticsearch-xp\lib\utils.js:30:12) at Function.synchronize [as esSynchronize] (C:....\node_modules\mongoose-elasticsearch-xp\lib\index.js:327:16) at Object. (C:/.../src/models/job.js:348:5)
at Module._compile (module.js:569:30)
at loader (C:....\node_modules\babel-register\lib\node.js:144:5)
at Object.require.extensions.(anonymous function) [as .js] (C:....\node_modules\babel-register\lib\node.js:154:7)
at Module.load (module.js:503:32)
at tryModuleLoad (module.js:466:12)
at Function.Module._load (module.js:458:3)
at Module.require (module.js:513:17)
at require (internal/module.js:11:18)
at Object. (C:.../src/lang/en/job.js:1:1)
at Module._compile (module.js:569:30)
at loader (C:....\node_modules\babel-register\lib\node.js:144:5)
at Object.require.extensions.(anonymous function) [as .js] (C:.....\node_modules\babel-register\lib\node.js:154:7)
at Module.load (module.js:503:32)
at tryModuleLoad (module.js:466:12)
at Function.Module._load (module.js:458:3)
at Module.require (module.js:513:17)
at require (internal/module.js:11:18)
at underscore2.default.each.file (C:../src/lang/index.js:17:12)
at Function..each._.forEach (C:....\node_modules\underscore\underscore.js:153:9)
at Object. (C:/..../src/lang/index.js:16:3)
at Module._compile (module.js:569:30)
at loader (C:....\node_modules\babel-register\lib\node.js:144:5)
at Object.require.extensions.(anonymous function) [as .js] (C:....\node_modules\babel-register\lib\node.js:154:7)
at Module.load (module.js:503:32)
at tryModuleLoad (module.js:466:12)
[nodemon] app crashed - waiting for file changes before starting...