$file->getMimeType() instead of $file->minor_mime