From c730dda86fa0ed9cea96061e7817a0bce24bc29b Mon Sep 17 00:00:00 2001 From: Brian Wolff Date: Wed, 29 Jun 2011 22:24:27 +0000 Subject: [PATCH] (follow-up r91106) Explicitly compare against the self::BROKEN_FILE constants. Before was doing if !$metadata, which used to work when self::BROKEN_FILE was 0, now it's -1 and that works less. --- includes/media/ExifBitmap.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/media/ExifBitmap.php b/includes/media/ExifBitmap.php index 42a2fd6887..2f981b3b7f 100644 --- a/includes/media/ExifBitmap.php +++ b/includes/media/ExifBitmap.php @@ -101,7 +101,8 @@ class ExifBitmapHandler extends BitmapHandler { */ function formatMetadata( $image ) { $metadata = $image->getMetadata(); - if ( !$metadata || + if ( $metadata === self::OLD_BROKEN_FILE || + $metadata === self::BROKEN_FILE || $this->isMetadataValid( $image, $metadata ) === self::METADATA_BAD ) { // So we don't try and display metadata from PagedTiffHandler -- 2.20.1