From 56c2b6be703d669a6f8581b922d747b122648f13 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jaime=20Pe=CC=81rez=20Crespo?= <jaime.perez@uninett.no>
Date: Wed, 12 Dec 2018 14:37:18 +0100
Subject: [PATCH] Actually fix the submit button in chrome.

The previous "fix" wasn't really fixing anything, it was indeed breaking the code that was changing the submit button, because jquery (and therefore "$") wasn't in scope for the script. Now, once jquery is available for that code, the bug appears again. This is due to an alleged "bug" in chrome, which prevents the button from actually working after it gets disabled. This makes full sense on the other hand, and as soon as we disable it, events won't keep being processed for that button, and as such, the form never gets submitted. This is why we need to submit the form manually.
---
 modules/core/www/assets/js/loginuserpass.js | 1 +
 1 file changed, 1 insertion(+)

diff --git a/modules/core/www/assets/js/loginuserpass.js b/modules/core/www/assets/js/loginuserpass.js
index eda960286..5a3054627 100644
--- a/modules/core/www/assets/js/loginuserpass.js
+++ b/modules/core/www/assets/js/loginuserpass.js
@@ -2,5 +2,6 @@ $(document).ready(function () {
     $('#submit_button').on('click', function () {
         $(this).attr('disabled', 'disabled');
         $(this).html($(this).data('processing'));
+        $(this).parents('form').submit();
     });
 });
-- 
GitLab