fix mime type resolution