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

Add sanity check for update participants notification #1122

Merged
merged 1 commit into from Mar 10, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 8 additions & 2 deletions NextcloudTalk/NCExternalSignalingController.m
Expand Up @@ -535,8 +535,14 @@ - (void)processRoomParticipantsEvent:(NSDictionary *)eventDict
[self.delegate externalSignalingController:self didReceivedParticipantListMessage:updateDict];

NSMutableDictionary *userInfo = [[NSMutableDictionary alloc] init];
[userInfo setObject:[updateDict objectForKey:@"roomid"] forKey:@"roomToken"];
[userInfo setObject:[updateDict objectForKey:@"users"] forKey:@"users"];
NSString *roomToken = [updateDict objectForKey:@"roomid"];
if (roomToken){
[userInfo setObject:roomToken forKey:@"roomToken"];
}
NSArray *users = [updateDict objectForKey:@"users"];
if (users) {
[userInfo setObject:users forKey:@"users"];
}
[[NSNotificationCenter defaultCenter] postNotificationName:NCExternalSignalingControllerDidUpdateParticipantsNotification
object:self
userInfo:userInfo];
Expand Down