fix json parsing for responses not application/json