=== HasException

This Matcher determines if the exception specified in the condition or
the subclasses of it has occurred during the processing of the mail.
If true, all recipients are returned, else null. This matcher presupposes
that the exception has been captured as a Mail attribute
org.apache.mailet.Mail#MAILET_ERROR_ATTRIBUTE_NAME in the process.

Sample configuration:

....
<mailet match="HasException=org.apache.james.managesieve.api.ManageSieveException" class="<any-class>">
....