Fix editor closing incorrectly when an error occurs

Fixes #558.
This commit is contained in:
Oliver Hamlet
2016-04-08 22:02:05 +01:00
parent c5b75df129
commit 6cafd65989
+1 -1
View File
@@ -479,7 +479,7 @@ function onEditorClose(evt) {
the editor has been closed. */
promise = loot.query('editorClosed');
}
promise.then(() => {
promise.catch(handlePromiseError).then(() => {
/* Remove body attribute so that sidebar items are styled correctly. */
document.body.removeAttribute('data-editors');
document.getElementById('cardsNav').notifyResize();