From: Aryeh Gregor Date: Sun, 21 Oct 2007 18:48:55 +0000 (+0000) Subject: There's no such thing as $this in static functions. Thanks, Nikerabbit. X-Git-Tag: 1.31.0-rc.0~51104 X-Git-Url: https://git.cyclocoop.org/%27.WWW_URL.%27admin/?a=commitdiff_plain;h=1c1399a3c9fb56e94c1a3e35f22bd5670ff661c8;p=lhc%2Fweb%2Fwiklou.git There's no such thing as $this in static functions. Thanks, Nikerabbit. --- diff --git a/docs/hooks.txt b/docs/hooks.txt index 0212dd060f..4866a30a11 100644 --- a/docs/hooks.txt +++ b/docs/hooks.txt @@ -520,7 +520,6 @@ after noinclude/includeonly/onlyinclude and other processing. tance to return false if the domain name doesn't match your organization $addr: The e-mail address entered by the user &$result: Set this and return false to override the internal checks -$user: User the address is being validated for 'isValidPassword': Override the result of User::isValidPassword() $password: The password entered by the user diff --git a/includes/User.php b/includes/User.php index 5f41c8ce7f..0d2865c61f 100644 --- a/includes/User.php +++ b/includes/User.php @@ -527,7 +527,7 @@ class User { */ public static function isValidEmailAddr( $addr ) { $result = null; - if( !wfRunHooks( 'isValidEmailAddr', array( $addr, &$result, $this ) ) ) { + if( !wfRunHooks( 'isValidEmailAddr', array( $addr, &$result ) ) ) { return $result; }