From 765231581cc774af1dd08dcc8711f0c1fbdec501 Mon Sep 17 00:00:00 2001 From: eight Date: Sat, 7 Oct 2017 18:10:00 +0800 Subject: [PATCH] Fix: onbeforeunload handler would disable the save button --- edit/edit.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/edit/edit.js b/edit/edit.js index 29ea1fff..130f7dd0 100644 --- a/edit/edit.js +++ b/edit/edit.js @@ -502,7 +502,7 @@ window.onbeforeunload = () => { rememberWindowSize(); } document.activeElement.blur(); - if (isCleanGlobal() && (!editor || !editor.isDirty())) { + if ((!editor && isCleanGlobal()) || (editor && !editor.isDirty())) { return; } updateLintReportIfEnabled(null, 0);