From 1100285027a799eca72d2f03b5d0555af05f6cfc Mon Sep 17 00:00:00 2001 From: Sam Reed Date: Fri, 18 Mar 2011 20:30:06 +0000 Subject: [PATCH] Followup r84260, normalise API behaviour, and fixup description --- includes/api/ApiQueryFilearchive.php | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/includes/api/ApiQueryFilearchive.php b/includes/api/ApiQueryFilearchive.php index 7201dd1604..36adbc12cf 100644 --- a/includes/api/ApiQueryFilearchive.php +++ b/includes/api/ApiQueryFilearchive.php @@ -138,15 +138,14 @@ class ApiQueryFilearchive extends ApiQueryBase { $file['userid'] = $row->fa_user; $file['user'] = $row->fa_user_text; } - if ( $fld_size ) { + if ( $fld_size || $fld_dimensions ) { $file['size'] = $row->fa_size; $pageCount = ArchivedFile::newFromRow( $row )->pageCount(); if ( $pageCount !== false ) { $vals['pagecount'] = $pageCount; } - } - if ( $fld_dimensions ) { + $file['height'] = $row->fa_height; $file['width'] = $row->fa_width; } @@ -240,7 +239,7 @@ class ApiQueryFilearchive extends ApiQueryBase { ' timestamp - Adds timestamp for the uploaded version', ' user - Adds user who uploaded the image version', ' size - Adds the size of the image in bytes and the height, width and page count (if applicable)', - ' dimensions - Adds the height and width of the image', + ' dimensions - Alias for size', ' description - Adds description the image version', ' mime - Adds MIME of the image', ' metadata - Lists EXIF metadata for the version of the image', -- 2.20.1