snowyu/loopback-component-auto-migrate.js

Uncaught TypeError: Cannot read property 'dataSource' of undefined (in v0.2.7)

Closed this issue · 3 comments

Starting with 0.2.7 I get

     Uncaught TypeError: Cannot read property 'dataSource' of undefined
      at node_modules/loopback-component-auto-migrate/lib/auto-migrate.js:26:41
      at tryCatcher (node_modules/bluebird/js/release/util.js:16:23)
      at MappingPromiseArray._promiseFulfilled (node_modules/bluebird/js/release/map.js:61:38)
      at MappingPromiseArray.PromiseArray._iterate (node_modules/bluebird/js/release/promise_array.js:114:31)
      at MappingPromiseArray.init (node_modules/bluebird/js/release/promise_array.js:78:10)
      at MappingPromiseArray._asyncInit (node_modules/bluebird/js/release/map.js:30:10)
      at Async._drainQueue (node_modules/bluebird/js/release/async.js:138:12)
      at Async._drainQueues (node_modules/bluebird/js/release/async.js:143:10)
      at Immediate.Async.drainQueues (node_modules/bluebird/js/release/async.js:17:14)

What is the steps to reproduce it?
This model is not eixsts or not connected to a datasource in your model-config.json.

The step to reproduce it in my case, is just change the version number to the defective 0.2.7!
Everything works great with 0.2.6 and below...

Ok, you can extract something from your case to show it.