Created
February 16, 2022 16:20
-
-
Save nosilver4u/848591cf7fb2671f17f86803a1a5e318 to your computer and use it in GitHub Desktop.
Prevent resizing of GIF images by Easy IO
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/* | |
Plugin Name: Easy IO GIF Skipper | |
Version: 1.0.0 | |
*/ | |
add_filter( 'exactdn_pre_args', 'easyio_skip_gif_resizing', 10, 2 ); | |
function easyio_skip_gif_resizing( $args, $image_url ) { | |
if ( strpos( $image_url, '.gif' ) ) { | |
return array(); | |
} | |
return $args; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment