mirror of
https://0xacab.org/sutty/sutty
synced 2024-11-15 23:41:42 +00:00
editor: No reportar error cuando no se selecciona un archivo para subir
This commit is contained in:
parent
eb1c12e362
commit
2a416b4e67
1 changed files with 4 additions and 2 deletions
|
@ -137,8 +137,10 @@ export function setupAuxiliaryToolbar(editor: Editor): void {
|
|||
"click",
|
||||
(event) => {
|
||||
const files = editor.toolbar.auxiliary.multimedia.fileEl.files;
|
||||
if (!files || !files.length)
|
||||
throw new Error("no hay archivos para subir");
|
||||
if (!files || !files.length) {
|
||||
console.info("no hay archivos para subir");
|
||||
return;
|
||||
}
|
||||
const file = files[0];
|
||||
|
||||
const selectedEl = editor.contentEl.querySelector<HTMLElement>(
|
||||
|
|
Loading…
Reference in a new issue