diff --git a/packages/core/strapi/lib/services/entity-service/components.js b/packages/core/strapi/lib/services/entity-service/components.js index 4244feaa95..c185810055 100644 --- a/packages/core/strapi/lib/services/entity-service/components.js +++ b/packages/core/strapi/lib/services/entity-service/components.js @@ -110,7 +110,8 @@ const getComponents = async (uid, entity) => { const componentAttributes = getComponentAttributes(strapi.getModel(uid)); if (_.isEmpty(componentAttributes)) return {}; - return strapi.query(uid).load(entity, componentAttributes); + const components = strapi.query(uid).load(entity, componentAttributes); + return { id: entity?.id, ...components }; }; /*