使用Sequelizejs获取类型错误

时间:2015-03-17 03:35:27

标签: node.js express sequelize.js

我得到以下错误,我无法通过堆栈跟踪弄清楚它出错的地方。

/Users/rahulsharma/Desktop/Jobletics/node_modules/sequelize/lib/sequelize.js:298
      this.importCache[path] = defineCall(this, DataTypes)
                               ^
TypeError: object is not a function
    at module.exports.Sequelize.import (/Users/ra/Desktop/Js/node_modules/sequelize/lib/sequelize.js:298:32)
    at db.sequelize (/Users/ra/Desktop/Js/models/index.js:14:33)
    at Array.forEach (native)
    at Object.<anonymous> (/Users/ra/Desktop/Js/models/index.js:13:4)
    at Module._compile (module.js:456:26)
    at Object.Module._extensions..js (module.js:474:10)
    at Module.load (module.js:356:32)
    at Function.Module._load (module.js:312:12)
    at Module.require (module.js:364:17)
    at require (module.js:380:17)

这是git:

https://github.com/rahul1346/jb

有什么想法吗?

1 个答案:

答案 0 :(得分:1)

business_model.js是一个空文件。