adds response code in error message