wp_query – Exclude the first thumbnail from lazy loading on archives
Filters must always return a value. If you do not return a value, it’s the same as returning an empty value, null, etc. This is always the first parameter, or a modified/replacement version of it. So this: add_filter( ‘wp_get_attachment_image_attributes’, function( $attrs ) { if ( !is_single() && !is_page() && is_front_page() && is_archive() && is_search() ) … Read more