diff options
author | zeripath <art27@cantab.net> | 2020-08-29 22:32:46 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-08-29 17:32:46 -0400 |
commit | 17fbbe97d7b4fca45d112f924191600eff52957b (patch) | |
tree | 81aacf1ad3cbf2c8017df3d017c3dfa7b5ff22ff /web_src/js | |
parent | 9abc16a280ca43b5b7007d0c9f292b0fffa46a4b (diff) | |
download | gitea-17fbbe97d7b4fca45d112f924191600eff52957b.tar.gz gitea-17fbbe97d7b4fca45d112f924191600eff52957b.zip |
Do not disable commit changes button on repost (#12644)
If the user has pressed commit changes and the post has failed - do not disable
the commit changes button.
Fix #12072
Signed-off-by: Andrew Thornton <art27@cantab.net>
Diffstat (limited to 'web_src/js')
-rw-r--r-- | web_src/js/index.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/web_src/js/index.js b/web_src/js/index.js index 810493a7d6..a8965a437f 100644 --- a/web_src/js/index.js +++ b/web_src/js/index.js @@ -1592,7 +1592,9 @@ async function initEditor() { const dirtyFileClass = 'dirty-file'; // Disabling the button at the start - $commitButton.prop('disabled', true); + if ($('input[name="page_has_posted"]').val() !== 'true') { + $commitButton.prop('disabled', true); + } // Registering a custom listener for the file path and the file content $editForm.areYouSure({ |