fix(speaker-stats): dispatch action only on change

This commit is contained in:
Hristo Terezov 2023-02-23 15:00:22 -06:00
parent 4aea40d34f
commit b033d0268a
1 changed files with 4 additions and 1 deletions

View File

@ -73,8 +73,11 @@ MiddlewareRegistry.register(({ dispatch, getState }: IStore) => (next: Function)
case PARTICIPANT_LEFT:
case PARTICIPANT_KICKED:
case PARTICIPANT_UPDATED: {
dispatch(initReorderStats());
const { pendingReorder } = getState()['features/speaker-stats'];
if (!pendingReorder) {
dispatch(initReorderStats());
}
break;
}