edit the part of error callback