From: Bryan Tong Minh Date: Thu, 29 May 2008 19:23:37 +0000 (+0000) Subject: Run UserLoginComplete hook from API X-Git-Tag: 1.31.0-rc.0~47298 X-Git-Url: http://git.cyclocoop.org/%24image?a=commitdiff_plain;h=04351dd272f75e9fc0074bba00d1d2190a54a1a3;p=lhc%2Fweb%2Fwiklou.git Run UserLoginComplete hook from API --- diff --git a/includes/api/ApiLogin.php b/includes/api/ApiLogin.php index 525ec2d9e7..4d54ee75bb 100644 --- a/includes/api/ApiLogin.php +++ b/includes/api/ApiLogin.php @@ -104,6 +104,11 @@ class ApiLogin extends ApiBase { $wgUser->setOption('rememberpassword', 1); $wgUser->setCookies(); + // Run hooks. FIXME: split back and frontend from this hook. + // FIXME: This hook should be placed in the backend + $injected_html = ''; + wfRunHooks('UserLoginComplete', array(&$wgUser, &$injected_html)); + $result['result'] = 'Success'; $result['lguserid'] = $wgUser->getId(); $result['lgusername'] = $wgUser->getName();