Merge "Remove parameter 'options' from hook 'SkinEditSectionLinks'"
[lhc/web/wiklou.git] / maintenance / cleanupUsersWithNoId.php
index b2fdf2f..f7fd9d5 100644 (file)
@@ -95,7 +95,7 @@ class CleanupUsersWithNoId extends LoggedUpdateMaintenance {
         * @param IDatabase $dbw
         * @param string[] $indexFields Fields in the index being ordered by
         * @param object $row Database row
-        * @return array [ string $next, string $display ]
+        * @return string[] [ string $next, string $display ]
         */
        private function makeNextCond( $dbw, $indexFields, $row ) {
                $next = '';
@@ -166,13 +166,13 @@ class CleanupUsersWithNoId extends LoggedUpdateMaintenance {
 
                                $id = 0;
                                if ( $this->assign ) {
-                                       $id = (int)User::idFromName( $name );
+                                       $id = User::idFromName( $name );
                                        if ( !$id ) {
                                                // See if any extension wants to create it.
                                                if ( !isset( $this->triedCreations[$name] ) ) {
                                                        $this->triedCreations[$name] = true;
                                                        if ( !Hooks::run( 'ImportHandleUnknownUser', [ $name ] ) ) {
-                                                               $id = (int)User::idFromName( $name, User::READ_LATEST );
+                                                               $id = User::idFromName( $name, User::READ_LATEST );
                                                        }
                                                }
                                        }