Skip to content

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.

feat(base/participants): fix max callstack error

Calin-Teodor7bc9913b29c4
diff --git a/react/features/base/participants/reducer.ts b/react/features/base/participants/reducer.ts
index c4edc956e2..25aad9b55a 100644
--- a/react/features/base/participants/reducer.ts
+++ b/react/features/base/participants/reducer.ts
@@ -118,17 +118,13 @@ ReducerRegistry.register<IParticipantsState>('features/base/participants',
case NOTIFIED_TO_SPEAK: {
return {
...state,
- raisedHandsQueue: state.raisedHandsQueue.map((item, index) => {
- if (index === 0) {
-
- return {
- ...item,
- hasBeenNotified: true
- };
- }
-
- return item;
- })
+ raisedHandsQueue: [
+ {
+ ...state.raisedHandsQueue[0],
+ hasBeenNotified: true
+ },
+ ...state.raisedHandsQueue.slice(1)
+ ]
};
}