- //org.ibex.mail.protocol.SMTP.Outgoing.accept(message);
- boolean ok = org.ibex.mail.protocol.SMTP.Outgoing.attempt(message);
- if (!ok) throw new JSExn("SMTP server rejected message");
- return JSU.T;
+
+ boolean ok = false;
+ try {
+ if (attempt) {
+ org.ibex.mail.protocol.SMTP.Outgoing.attempt(message);
+ } else {
+ org.ibex.mail.protocol.SMTP.Outgoing.accept(message);
+ }
+ ok = true;
+ } catch (Exception ex) {
+ if (!attempt) Log.warn(this, ex);
+ }
+ if (!ok && !attempt) throw new JSExn("SMTP server rejected message");
+ return JSU.B(ok);