activecampaign-api-nodejs
activecampaign-api-nodejs copied to clipboard
[BUG] Wrong error handling when 503 error message is received from ActiveCampaign API.
When activeCampaign load balancer returns a 503 error message. The NodeJS package is not able to parse or generate the response and returns the string "Error:", instead of "Error: ${error.message}" or something like that.
Expected behavior:
- Returning the Error object
- Return descriptive Error message for cases like those.
Current Behavior:
- Returns an empty string as error
- Try catch returns a string as an error, instead of an error object.