Client script: checking for problems when calling a connection

Client script: checking for problems when calling a connection

Hi everyone!

I'm writing a Client Script in which I need to use a Connection to call our custom ERP.
I'm doing something like:

var res = ZDK.Apps.CRM.Connections.invoke("myerp", "https://our.url/path",  "POST", 1, parameters, headers);

and it works, so now I'm trying to build some error handling in my code.
As a first step, I'd like to test if there's a network problem, so I altered the url to something unexistent. In this case, res.code and res.status still contain "SUCCESS", is this normal?