Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Command status codes related to official SMPP Spec Error Codes #234

Closed
elhananjair opened this issue Jul 15, 2023 · 0 comments
Closed

Command status codes related to official SMPP Spec Error Codes #234

elhananjair opened this issue Jul 15, 2023 · 0 comments

Comments

@elhananjair
Copy link

Hello there,
I just read about handling errors on this package like this:

session.on('error', function(e) {
	// empty callback to catch emitted errors to prevent exit due unhandled errors
	if (e.code === "ETIMEOUT") {
		// TIMEOUT
	} else if (e.code === "ECONNREFUSED" {
		// CONNECTION REFUSED
	} else {
		// OTHER ERROR
	}
});

isn't it better to map error codes to make it similar to the one with SMPP Spec? the one used on the above code is obscure relating to the spec, and does all SMPP Error codes implemented on this library? Thanks.
reference: https://smpp.org/smpp-error-codes.html

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant