Skip to content

Commit d4c3f68

Browse files
authored
fix: user attribute issue (#1581)
Signed-off-by: Tipu_Singh <tipu.singh@ayanworks.com>
1 parent e06d293 commit d4c3f68

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

libs/client-registration/src/client-registration.service.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -849,8 +849,7 @@ export class ClientRegistrationService {
849849

850850
attributes.ecosystem_access = [JSON.stringify(ecosystemAccess)];
851851

852-
// Update user in Keycloak
853-
const updatePayload = { attributes };
852+
const updatePayload = { ...currentUser, attributes };
854853
this.logger.log(`[updateUserEcosystemAccess] Sending update to Keycloak...`);
855854

856855
await this.commonService.httpPut(userUrl, updatePayload, this.getAuthHeader(token));
@@ -1022,7 +1021,7 @@ export class ClientRegistrationService {
10221021
this.logger.log(`[removeUserEcosystemAccess] Removed ecosystem_access attribute (empty)`);
10231022
}
10241023

1025-
const updatePayload = { attributes };
1024+
const updatePayload = { ...currentUser, attributes };
10261025
this.logger.log(`[removeUserEcosystemAccess] Sending update to Keycloak...`);
10271026

10281027
await this.commonService.httpPut(userUrl, updatePayload, this.getAuthHeader(token));

0 commit comments

Comments
 (0)