Deprecate defunct Skin::getCommonStylePath()
[lhc/web/wiklou.git] / includes / User.php
index fe41187..4557096 100644 (file)
@@ -829,7 +829,7 @@ class User implements IDBAccessObject {
         * @param int $ts Optional timestamp to convert, default 0 for the current time
         */
        public function expirePassword( $ts = 0 ) {
-               $this->load();
+               $this->loadPasswords();
                $timestamp = wfTimestamp( TS_MW, $ts );
                $this->mPasswordExpires = $timestamp;
                $this->saveSettings();
@@ -1885,7 +1885,6 @@ class User implements IDBAccessObject {
                        return $this->mLocked;
                }
                global $wgAuth;
-               StubObject::unstub( $wgAuth );
                $authUser = $wgAuth->getUserInstance( $this );
                $this->mLocked = (bool)$authUser->isLocked();
                return $this->mLocked;
@@ -1903,7 +1902,6 @@ class User implements IDBAccessObject {
                $this->getBlockedStatus();
                if ( !$this->mHideName ) {
                        global $wgAuth;
-                       StubObject::unstub( $wgAuth );
                        $authUser = $wgAuth->getUserInstance( $this );
                        $this->mHideName = (bool)$authUser->isHidden();
                }
@@ -2733,7 +2731,7 @@ class User implements IDBAccessObject {
 
                                foreach ( $columns as $column ) {
                                        foreach ( $rows as $row ) {
-                                               $checkmatrixOptions["$prefix-$column-$row"] = true;
+                                               $checkmatrixOptions["$prefix$column-$row"] = true;
                                        }
                                }
 
@@ -3086,10 +3084,8 @@ class User implements IDBAccessObject {
        /**
         * Check if user is allowed to access a feature / make an action
         *
-        * @internal param \String $varargs permissions to test
+        * @param string $permissions,... Permissions to test
         * @return bool True if user is allowed to perform *any* of the given actions
-        *
-        * @return bool
         */
        public function isAllowedAny( /*...*/ ) {
                $permissions = func_get_args();
@@ -3103,7 +3099,7 @@ class User implements IDBAccessObject {
 
        /**
         *
-        * @internal param $varargs string
+        * @param string $permissions,... Permissions to test
         * @return bool True if the user is allowed to perform *all* of the given actions
         */
        public function isAllowedAll( /*...*/ ) {
@@ -3790,12 +3786,14 @@ class User implements IDBAccessObject {
         */
        public function checkPassword( $password ) {
                global $wgAuth, $wgLegacyEncoding;
+
+               $section = new ProfileSection( __METHOD__ );
+
                $this->loadPasswords();
 
                // Certain authentication plugins do NOT want to save
                // domain passwords in a mysql database, so we should
                // check this (in case $wgAuth->strict() is false).
-
                if ( $wgAuth->authenticate( $this->getName(), $password ) ) {
                        return true;
                } elseif ( $wgAuth->strict() ) {