mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-12 04:18:54 +00:00
style: add no-misused-promises rule (#3547)
Co-authored-by: Peng Xiao <pengxiao@outlook.com>
This commit is contained in:
@@ -34,9 +34,12 @@ const Actions = () => {
|
||||
/>
|
||||
<IconButton
|
||||
className={sendButtonStyle}
|
||||
onClick={useCallback(async () => {
|
||||
await call(input);
|
||||
await generateFollowingUp();
|
||||
onClick={useCallback(() => {
|
||||
call(input)
|
||||
.then(() => generateFollowingUp())
|
||||
.catch(e => {
|
||||
console.error(e);
|
||||
});
|
||||
}, [call, generateFollowingUp, input])}
|
||||
>
|
||||
<SendIcon />
|
||||
|
||||
Reference in New Issue
Block a user