Fixes detection for image file: cURL might not detect content-type correctly