The title says it all
If the first rule calls the callback with an error, will the next rule execute?
Thanks for the help.
The title says it all
If the first rule calls the callback with an error, will the next rule execute?
Thanks for the help.
Hey there @alexab!
Good question. Need to check! Will get back to you shortly!
There’s no info about that in our docs about rules:
Alex what I would suggest is to create a blank rule below the rule that calls the callback with an error that simply prints something and check trying this out.
Ok - fair suggestion I will get back with my findings when I have the time
Hi again @alexab,
Coming from your other topic.
No, the subsequent rules will not run if the previous returns the callback with an error like callback(new UnauthorizedError('Invalid IP address'));
Hope this helps!
Hi Dan - this helps a lot Something that might be missing from the official documentation?
It is mentioned in the rules best practices docs:
The status parameter should be passed as either
null
, an instance of anError
object, or an instance of anUnauthorizedError
object. Specifying null will permit the continuation of pipeline processing, while any of the other values will terminate the pipeline; anUnauthorizedError
signals denial of access and allows information to be returned to the originator of the authentication operation regarding the reason why access is denied. Passing any other value for any of these parameters will have unpredictable results and may lead to an exception or error condition.
This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.