Merge "Update weblinks in comments from HTTP to HTTPS"
[lhc/web/wiklou.git] / includes / user / User.php
index 4a34371..273d555 100644 (file)
@@ -26,6 +26,7 @@ use MediaWiki\Session\Token;
 use MediaWiki\Auth\AuthManager;
 use MediaWiki\Auth\AuthenticationResponse;
 use MediaWiki\Auth\AuthenticationRequest;
+use Wikimedia\ScopedCallback;
 
 /**
  * String Some punctuation to prevent editing from broken text-mangling proxies.
@@ -320,7 +321,7 @@ class User implements IDBAccessObject {
         * @return string
         */
        public function __toString() {
-               return $this->getName();
+               return (string)$this->getName();
        }
 
        /**
@@ -1657,7 +1658,6 @@ class User implements IDBAccessObject {
 
                // Extensions
                Hooks::run( 'GetBlockedStatus', [ &$this ] );
-
        }
 
        /**
@@ -1689,7 +1689,6 @@ class User implements IDBAccessObject {
         * @return bool True if blacklisted.
         */
        public function inDnsBlacklist( $ip, $bases ) {
-
                $found = false;
                // @todo FIXME: IPv6 ???  (https://bugs.php.net/bug.php?id=33170)
                if ( IP::isIPv4( $ip ) ) {