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

Commit 23c6c854 by Mick Hansen

remove associations array from sequelize, wasn\'t needed anyway

1 parent a4c10f8c
......@@ -47,7 +47,6 @@ Mixin.hasMany = function(associatedDAOFactory, options) {
// the id is in the foreign table or in a connecting table
var association = new HasMany(this, associatedDAOFactory, Utils._.extend((options||{}), this.options))
this.associations[association.associationAccessor] = association.injectAttributes()
associatedDAOFactory.daoFactoryManager.sequelize.associations.push(association)
association.injectGetter(this.DAO.prototype)
association.injectSetter(this.DAO.prototype)
......
......@@ -114,7 +114,6 @@ module.exports = (function() {
this.daoFactoryManager = new DAOFactoryManager(this)
this.transactionManager = new TransactionManager(this)
this.associations = []
this.importCache = {}
}
......
......@@ -899,7 +899,7 @@ describe(Support.getTestDialectTeaser("HasMany"), function() {
})
})
describe('as', function () {
describe('alias', function () {
it("creates the join table when through is a string", function (done) {
var self = this
, User = this.sequelize.define('User', {})
......
......@@ -83,7 +83,6 @@ var Support = {
.dropAllTables()
.success(function() {
sequelize.daoFactoryManager.daos = []
sequelize.associations = []
callback && callback()
})
.error(function(err) { console.log(err) })
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!