Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(metadata): Keeps track of participants last used display name. #546

Merged
merged 2 commits into from
Sep 17, 2024

Conversation

damencho
Copy link
Member

No description provided.

}
}
);
APP.conference._room.room.addListener(
"xmpp.display_name_changed",
(jid, displayName) => {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Skip if display name is undefined or 0 length.

(jid, displayName) => {
const identity = window._jibriParticipants.get(jid);
if (identity) {
identity.lastKnownDisplayName = displayName;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pl set the display name property instead, so the JaaS webhook payload doesn't change since it takes it from the metadata file.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So identity already has the display name that is coming from the jwt. Do you want to override that one and lost any values from it?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see, to overwrite name in user:

{
  "user": {
    "id": "123",
    "name": "damencho",
    "avatar": "https://"
  },
  "group": "456"
}

@damencho damencho merged commit 744975d into master Sep 17, 2024
2 checks passed
@damencho damencho deleted the last-known-displayName branch September 17, 2024 18:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants