mirror of
https://github.com/vector-im/element-call.git
synced 2024-11-15 00:04:59 +08:00
Don't try to promote the same speaker multiple times
This commit is contained in:
parent
ddeb36db47
commit
cd7ab00d80
@ -690,8 +690,13 @@ export function promoteSpeakers(g: Grid) {
|
||||
for (let j = 0; j < 10; j++) {
|
||||
const to = Math.floor(Math.random() * firstPageEnd);
|
||||
const toCell = g.cells[to];
|
||||
if (toCell === undefined || (toCell.columns === 1 && toCell.rows === 1))
|
||||
if (
|
||||
toCell === undefined ||
|
||||
(toCell.columns === 1 && toCell.rows === 1)
|
||||
) {
|
||||
moveTile(g, from, to);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user