Skip to content

Commit

Permalink
update: status codes
Browse files Browse the repository at this point in the history
Signed-off-by: svetoslav-nikol0v <[email protected]>
  • Loading branch information
svetoslav-nikol0v committed Jun 11, 2024
1 parent 9377fbb commit 1b83c8d
Showing 1 changed file with 24 additions and 0 deletions.
24 changes: 24 additions & 0 deletions src/Status.js
Original file line number Diff line number Diff line change
Expand Up @@ -651,6 +651,18 @@ export default class Status {
return "INVALID_GRPC_CERTIFICATE";
case Status.InvalidMaxAutoAssociations:
return "INVALID_MAX_AUTO_ASSOCIATIONS";
case Status.MaxNodesCreated:
return "MAX_NODES_CREATED";
case Status.IpFqdnCannotBeSetForSameEndpoint:
return "IP_FQDN_CANNOT_BE_SET_FOR_SAME_ENDPOINT";
case Status.GossipEndpointCannotHaveFqdn:
return "GOSSIP_ENDPOINT_CANNOT_HAVE_FQDN";
case Status.FqdnSizeTooLarge:
return "FQDN_SIZE_TOO_LARGE";
case Status.InvalidEndpoint:
return "INVALID_ENDPOINT";
case Status.GossipEndpointsExceededLimit:
return "GOSSIP_ENDPOINTS_EXCEEDED_LIMIT";
default:
return `UNKNOWN (${this._code})`;
}
Expand Down Expand Up @@ -1273,6 +1285,18 @@ export default class Status {
return Status.InvalidGrpcCertificate;
case 346:
return Status.InvalidMaxAutoAssociations;
case 347:
return Status.MaxNodesCreated;
case 348:
return Status.IpFqdnCannotBeSetForSameEndpoint;
case 349:
return Status.GossipEndpointCannotHaveFqdn;
case 350:
return Status.FqdnSizeTooLarge;
case 351:
return Status.InvalidEndpoint;
case 352:
return Status.GossipEndpointsExceededLimit;
default:
throw new Error(
`(BUG) Status.fromCode() does not handle code: ${code}`,
Expand Down

0 comments on commit 1b83c8d

Please sign in to comment.