fix recursive state updates (#1458)
This commit is contained in:
parent
50429a3513
commit
ed3d14b131
1 changed files with 1 additions and 1 deletions
|
@ -187,7 +187,7 @@ export const RoomInput = forwardRef<HTMLDivElement, RoomInputProps>(
|
||||||
const parsedDraft = JSON.parse(JSON.stringify(editor.children));
|
const parsedDraft = JSON.parse(JSON.stringify(editor.children));
|
||||||
setMsgDraft(parsedDraft);
|
setMsgDraft(parsedDraft);
|
||||||
} else {
|
} else {
|
||||||
roomIdToMsgDraftAtomFamily.remove(roomId);
|
setMsgDraft([]);
|
||||||
}
|
}
|
||||||
resetEditor(editor);
|
resetEditor(editor);
|
||||||
resetEditorHistory(editor);
|
resetEditorHistory(editor);
|
||||||
|
|
Loading…
Reference in a new issue