fixing to wrap errors in a ForecastError and only JSON.parsing when application/json