From: Roan Kattouw Date: Mon, 14 Apr 2008 13:27:30 +0000 (+0000) Subject: API: action=login now returns the correct waiting time in the details property X-Git-Tag: 1.31.0-rc.0~48344 X-Git-Url: https://git.cyclocoop.org/%20%27.%28%24debut%20%20%20%24par_page%29.%27?a=commitdiff_plain;h=133a033789ff910eccbbbd1aed144d7994cca7e4;p=lhc%2Fweb%2Fwiklou.git API: action=login now returns the correct waiting time in the details property --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index 28546b49a8..3abb9d11ad 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -225,6 +225,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * (bug 13618) Added rcprop=redirect and rcshow=redirect to list=recentchanges * (bug 13544) Added oldid parameter to action=parse to allow for parsing of old revisions * (bug 13718) Return the proper continue parameter for cmsort=timestamp +* action=login now returns the correct waiting time in the details property === Languages updated in 1.13 === diff --git a/includes/api/ApiLogin.php b/includes/api/ApiLogin.php index e67de4ad43..6ecf46490f 100644 --- a/includes/api/ApiLogin.php +++ b/includes/api/ApiLogin.php @@ -135,8 +135,9 @@ class ApiLogin extends ApiBase { } if ($result['result'] != 'Success') { - $result['wait'] = $this->cacheBadLogin(); - $result['details'] = "Please wait " . self::THROTTLE_TIME . " seconds before next log-in attempt"; + $delay = $this->cacheBadLogin(); + $result['wait'] = $delay; + $result['details'] = "Please wait " . $delay . " seconds before next log-in attempt"; } // if we were allowed to try to login, memcache is fine