Disable PDF thumbnails

To disable the PDF thumbnails, introduced in WordPress 4.7, use this snippet:

function wpkb_disable_pdf_thumbnail() { 
    $fallbacksizes = array(); 
    return $fallbacksizes; 
} 

add_filter('fallback_intermediate_image_sizes', 'wpkb_disable_pdf_thumbnail');