title: N:M eager loading (include) using sequelizejs
body: <p>So I found myself into troubles trying to use the include eager loading feature in M:N relations</p>
  
  <p>The user model relation:</p>
  
  <pre><code>User.belongsToMany(models.rol, {
        through: {
          model: models['usuario_rol']
        },
        as: {
          plural: 'roles',
          singular: 'rol'
        },
        foreignKey: 'idusuario'
  });
  </code></pre>
  
  <p>The rol model relation:</p>
  
  <pre><code>Rol.belongsToMany(models.usuario, {
        through: {
          model: models['usuario_rol']
        },
        foreignKey: 'idrol'
  });
  </code></pre>
  
  <p>Finally the query:</p>
  
  <pre><code>db.usuario.findOne({
      where: {
        id: insert.id
      },
      include: [
        {
          model: db.rol
        }
      ]
  });
  </code></pre>
  
  <p>If we try this the it crashes with Error: rol is not associated to usuario!</p>
  
  <p>The curious is that with an instance of the sequelize user object I can fetch the roles using user.getRoles()</p>
  
  <p>Do you have any idea of why is this happening?</p>