Add condition to deal with non-200 responses