sequelize-auto
sequelize-auto copied to clipboard
added noAlias check on BelongsToMany relation
on noAlias = true
Before:
roles.belongsToMany(permissions, { as: 'permissionIdPermissions', through: rolePermissions, foreignKey: "roleId", otherKey: "permissionId" });
After:
roles.belongsToMany(permissions, { through: rolePermissions, foreignKey: "roleId", otherKey: "permissionId" });