Skip to content

Commit

Permalink
fix: improve condition
Browse files Browse the repository at this point in the history
  • Loading branch information
raviteja83 committed Feb 26, 2024
1 parent 304e07e commit 2a2016a
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,15 @@ export const useRoleProminencePeers = (prominentRoles: string[], peers: HMSPeer[
}
return acc;
}
if (peer.isLocal && isInsetEnabled && !prominentRoles?.includes(peer.roleName || '')) {
return acc;
}
if (prominentRoles?.includes(peer.roleName || '')) {
acc[0].push(peer);
} else {
acc[1].push(peer);
}
if (peer.isLocal && isInsetEnabled) {
return acc;
}

return acc;
},
[[], []],
Expand Down

0 comments on commit 2a2016a

Please sign in to comment.