[ADF-5582] Fix avatar rendering logic in adf-node-comments (#10995)

* [ADF-5582] Update NodeCommentsService to take userId as an argument in getUserImage

* [ADF-5582] Add unit tests for avatar caching and retrieval in NodeCommentsService

* Refactor NodeCommentsService unit tests to avoid accessing private members

* [ADF-5582] Remove picture Id from getUserImage

* [ADF-5582] Add comment to getAvatarCache and fix sonarcloud issues

* Update node-comments.service.spec.ts

* Trigger sonar

* [ADF-5582] Add method to return avatar url in people api

* [ADF-5582] Fix sonar cloud issue

* [ADF-5582] Add comment to getUserImage and fix request address for getAvatarImageUrl
This commit is contained in:
Shivangi Shree
2025-08-05 16:54:58 +05:30
committed by GitHub
parent 8ef0aee768
commit 9a0b75caa1
5 changed files with 88 additions and 21 deletions

View File

@@ -20,7 +20,7 @@ Adds and retrieves comments for nodes in Content Services.
Gets all comments that have been added to a task.
- _id:_ `string` - ID of the target task
- **Returns** [`Observable`](http://reactivex.io/documentation/observable.html)`<`[`CommentModel`](../../../lib/core/src/lib/models/comment.model.ts)`[]>` - Details for each comment
- **getUserImage**(avatarId: `string`): `string`<br/>
Gets the URL for the user's profile image.
- _avatarId:_ `string` - ID of the user
- **Returns** `string` - URL for the user's profile image
- **getUserImage**(userId: `string`): `string`<br/>
Returns the avatar URL for the specified user.
- _userId:_ `string` - ID of the user
- **Returns** `string` - URL of the user's avatar image