aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--core/Controller/LostController.php1
-rw-r--r--core/js/lostpassword.js4
2 files changed, 4 insertions, 1 deletions
diff --git a/core/Controller/LostController.php b/core/Controller/LostController.php
index 8d26f2c1942..27491b88235 100644
--- a/core/Controller/LostController.php
+++ b/core/Controller/LostController.php
@@ -206,6 +206,7 @@ class LostController extends Controller {
/**
* @PublicPage
* @BruteForceProtection(action=passwordResetEmail)
+ * @AnonRateThrottle(limit=10, period=300)
*
* @param string $user
* @return JSONResponse
diff --git a/core/js/lostpassword.js b/core/js/lostpassword.js
index 6e18dcc1f8b..4690b86f995 100644
--- a/core/js/lostpassword.js
+++ b/core/js/lostpassword.js
@@ -31,7 +31,9 @@ OC.Lostpassword = {
user : $('#user').val()
},
OC.Lostpassword.sendLinkDone
- );
+ ).fail(function() {
+ OC.Lostpassword.sendLinkError(OC.Lostpassword.sendErrorMsg);
+ });
}
}
},