changed add_error to addError