From f08abed85195b4a6884b6b7747083b562982a87e Mon Sep 17 00:00:00 2001
From: jrfnl <jrfnl@users.noreply.github.com>
Date: Sat, 27 Jul 2019 04:30:57 +0200
Subject: [PATCH] [src] Remove work-arounds for IMAGETYPE_ICO
---
src/wp-admin/includes/image.php | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/src/wp-admin/includes/image.php b/src/wp-admin/includes/image.php
index bcdc2411f0..aa905254da 100644
a
|
b
|
function file_is_valid_image( $path ) { |
795 | 795 | * @return bool True if suitable, false if not suitable. |
796 | 796 | */ |
797 | 797 | function file_is_displayable_image( $path ) { |
798 | | $displayable_image_types = array( IMAGETYPE_GIF, IMAGETYPE_JPEG, IMAGETYPE_PNG, IMAGETYPE_BMP ); |
799 | | |
800 | | // IMAGETYPE_ICO is only defined in PHP 5.3+. |
801 | | if ( defined( 'IMAGETYPE_ICO' ) ) { |
802 | | $displayable_image_types[] = IMAGETYPE_ICO; |
803 | | } |
| 798 | $displayable_image_types = array( IMAGETYPE_GIF, IMAGETYPE_JPEG, IMAGETYPE_PNG, IMAGETYPE_BMP, IMAGETYPE_ICO ); |
804 | 799 | |
805 | 800 | $info = @getimagesize( $path ); |
806 | 801 | if ( empty( $info ) ) { |