mirror of
https://github.com/stoatchat/for-legacy-web.git
synced 2026-03-07 09:25:27 +00:00
Make sure to focus window for desktop notifs.
Prevent empty pastes of files. Log push errors.
This commit is contained in:
@@ -263,6 +263,8 @@ function MessageBox({ channel, draft, dispatcher }: Props) {
|
||||
onChange={files => setUploadState({ type: "attached", files })}
|
||||
cancel={() => uploadState.type === 'uploading' && uploadState.cancel.cancel("cancel")}
|
||||
append={files => {
|
||||
if (files.length === 0) return;
|
||||
|
||||
if (uploadState.type === 'none') {
|
||||
setUploadState({ type: 'attached', files });
|
||||
} else if (uploadState.type === 'attached') {
|
||||
|
||||
Reference in New Issue
Block a user