]> source.dussan.org Git - nextcloud-server.git/commitdiff
Hide submit button after password change
authorLukas Reschke <lukas@owncloud.com>
Wed, 29 Oct 2014 12:26:24 +0000 (13:26 +0100)
committerLukas Reschke <lukas@owncloud.com>
Mon, 17 Nov 2014 16:50:20 +0000 (17:50 +0100)
Creating a new key pair can take 1-2 seconds. So it could happen that the user click the "Reset password" button again which can lead to many nasty things, e.g. we could create two new key pairs in parallel.

core/js/lostpassword.js

index aa1a864ffedad53dac6bf10999bdafdb0c78e467..7145e219654adf0ed94d2954abfa564c5f8465b7 100644 (file)
@@ -82,6 +82,9 @@ OC.Lostpassword = {
                                        OC.Lostpassword.resetDone
                        );
                }
+               if($('#encrypted-continue').attr('checked')) {
+                       $('#reset-password #submit').hide();
+               }
        },
 
        resetDone : function(result){