Retrieve roles without populating users and permissions relations

This commit is contained in:
Victor LAMBERT 2019-11-14 16:36:35 +01:00
parent 5f28916210
commit 59aff0af3c

View File

@ -389,7 +389,9 @@ module.exports = {
};
// Retrieve roles
const roles = await strapi.query('role', 'users-permissions').find();
const roles = await strapi
.query('role', 'users-permissions')
.find({}, []);
// We have to know the difference to add or remove
// the permissions entries in the database.