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

fix(xmpp): Fixes skipping messages when disco-info is processed late. #2565

Merged
merged 1 commit into from
Sep 4, 2024

Conversation

damencho
Copy link
Member

@damencho damencho commented Sep 4, 2024

When using bosh and xmpp conference-request (no jiconop on server-side) we can drop av moderation and speaker-stats messages.

When using bosh and xmpp conference-request (no jiconop on server-side) we can drop av moderation and speaker-stats messages.
saghul
saghul previously approved these changes Sep 4, 2024
Copy link
Member

@saghul saghul left a comment

Choose a reason for hiding this comment

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

LGTM, good catch!

@@ -508,8 +514,9 @@ export default class XMPP extends Listenable {
this._maybeSendDeploymentInfoStat(true);

if (this._components.length > 0) {
Copy link
Member

Choose a reason for hiding this comment

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

Drop the if since it's always initialized to an array?

Copy link
Member

Choose a reason for hiding this comment

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

@saghul Why do we want to drop the if? Technically we don't check only if it is array but also if we have added components in it, right? It seems still valid to me.

Copy link
Member Author

Choose a reason for hiding this comment

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

By default components is empty and we will iterate over the messages and don't do anything. So its not a big deal with the check ...

Copy link
Member

Choose a reason for hiding this comment

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

I understand that functionally it wont change anything. I'm asking technically what is the advantage to iterate over the messages and call the function so that it will quickly exit versus just having the check?

saghul
saghul previously approved these changes Sep 4, 2024
jallamsetty1
jallamsetty1 previously approved these changes Sep 4, 2024
@damencho damencho merged commit 6771b69 into master Sep 4, 2024
3 checks passed
@damencho damencho deleted the fix-av-mod branch September 4, 2024 15:41
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.

4 participants