Extract method `hasCorrectMimeType` or so?