Ori.livneh has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/313547

Change subject: Keep counts of login errors by type
......................................................................

Keep counts of login errors by type

For obvious reasons: to catch bugs and estimate their impact.
Use the message key as a proxy for error type.

Change-Id: I927e334f19845d0c49ce5870b3e0ff93b06c687b
---
M includes/specials/SpecialCentralLogin.php
1 file changed, 2 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/CentralAuth 
refs/changes/47/313547/1

diff --git a/includes/specials/SpecialCentralLogin.php 
b/includes/specials/SpecialCentralLogin.php
index da1d70a..80e3031 100644
--- a/includes/specials/SpecialCentralLogin.php
+++ b/includes/specials/SpecialCentralLogin.php
@@ -307,6 +307,8 @@
 
        protected function showError( /* varargs */ ) {
                $args = func_get_args();
+               RequestContext::getMain()->getStats()->increment(
+                       'centralauth.login_errors.' . $args[0] );
                $this->getOutput()->wrapWikiMsg( '<div class="error">$1</div>', 
$args );
                $this->getOutput()->addHtml( '<p 
id="centralauth-backlink-section"></p>' ); // JS only
        }

-- 
To view, visit https://gerrit.wikimedia.org/r/313547
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I927e334f19845d0c49ce5870b3e0ff93b06c687b
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/CentralAuth
Gerrit-Branch: master
Gerrit-Owner: Ori.livneh <o...@wikimedia.org>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to