From: Eduardo San Martin Morote Date: Fri, 25 Jun 2021 16:40:07 +0000 (+0200) Subject: refactor(devtools): reject on fileInput error X-Git-Tag: v2.0.0-beta.5~18 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=90dc6b683b214d0ea44f2a989ae5ff2268fd60de;p=thirdparty%2Fvuejs%2Fpinia.git refactor(devtools): reject on fileInput error --- diff --git a/src/devtools/actions.ts b/src/devtools/actions.ts index 43f4c388..443f3cc7 100644 --- a/src/devtools/actions.ts +++ b/src/devtools/actions.ts @@ -84,6 +84,7 @@ function getFileOpener() { return resolve({ text: await file.text(), file }) } fileInput!.oncancel = () => resolve(null) + fileInput!.onerror = reject fileInput!.click() }) }