You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-22 04:02:40 +03:00
Do...while loops are a thing
This commit is contained in:
@@ -573,7 +573,7 @@ export default class MessageComposerInput extends React.Component {
|
||||
}
|
||||
|
||||
// emojioneify any emoji
|
||||
while (true) {
|
||||
do {
|
||||
let foundEmoji = false;
|
||||
|
||||
for (const node of editorState.document.getTexts()) {
|
||||
@@ -607,9 +607,7 @@ export default class MessageComposerInput extends React.Component {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (!foundEmoji) break;
|
||||
}
|
||||
} while (foundEmoji);
|
||||
|
||||
// work around weird bug where inserting emoji via the macOS
|
||||
// emoji picker can leave the selection stuck in the emoji's
|
||||
|
||||
Reference in New Issue
Block a user