ignore fileOpen error when user cancels (#1486)

This commit is contained in:
David Luzar 2020-04-25 18:02:31 +02:00 committed by GitHub
parent 1866074c07
commit a4b49ea350
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -112,6 +112,10 @@ export const actionLoadScene = register({
updateData({ elements: elements, appState: appState });
})
.catch((error) => {
// if user cancels, ignore the error
if (error.name === "AbortError") {
return;
}
updateData({ error: error.message });
});
}}