Change error code for PhoneNumberTooLongException
This commit is contained in:
parent
2e1dfefaed
commit
5a4a37ce9a
|
@ -65,7 +65,7 @@ void reportException(const std::exception& exception) {
|
||||||
std::string phone_number = too_long->number_string();
|
std::string phone_number = too_long->number_string();
|
||||||
phone_number += '\0';
|
phone_number += '\0';
|
||||||
ereport(ERROR,
|
ereport(ERROR,
|
||||||
(errcode(ERRCODE_NUMERIC_VALUE_OUT_OF_RANGE),
|
(errcode(ERRCODE_INVALID_TEXT_REPRESENTATION),
|
||||||
errmsg("phone number '%s' is too long", phone_number.data()),
|
errmsg("phone number '%s' is too long", phone_number.data()),
|
||||||
errdetail("%s", exception.what())));
|
errdetail("%s", exception.what())));
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue