Index: trunk/phase3/includes/api/ApiQueryImageInfo.php |
— | — | @@ -201,7 +201,8 @@ |
202 | 202 | |
203 | 203 | if ( isset( $prop['user'] ) ) { |
204 | 204 | $vals['user'] = $file->getUser(); |
205 | | - } else if ( isset( $prop['userid'] ) ) { |
| 205 | + } |
| 206 | + if ( isset( $prop['userid'] ) ) { |
206 | 207 | $vals['userid'] = $file->getUser( 'id' ); |
207 | 208 | } |
208 | 209 | if ( !$file->getUser( 'id' ) ) { |
Index: trunk/phase3/includes/api/ApiQueryRevisions.php |
— | — | @@ -372,7 +372,8 @@ |
373 | 373 | } else { |
374 | 374 | if ( $this->fld_user ) { |
375 | 375 | $vals['user'] = $revision->getUserText(); |
376 | | - } else { |
| 376 | + } |
| 377 | + if ( $this->fld_userid ) { |
377 | 378 | $user = User::newFromText( $revision->getUserText() ); |
378 | 379 | $vals['userid'] = $user->getId(); |
379 | 380 | } |