IDEMPIERE-5289 Apply Packin from Folder is stopping when sending email throws error (FHCA-3601) (#1333)

This commit is contained in:
Carlos Ruiz 2022-05-18 04:09:53 +02:00 committed by GitHub
parent d67ca5b69b
commit 05e7c5eac7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 8 additions and 1 deletions

View File

@ -160,7 +160,14 @@ public class PackInNotifier {
from = sysclient.getRequestEMail();
}
EMail email = client.createEMailFrom(from, to, subject.toString(), message.toString(), false);
EMail email;
try {
email = client.createEMailFrom(from, to, subject.toString(), message.toString(), false);
} catch (Exception e) {
// ignore exceptions when the email cannot be created, just log it
e.printStackTrace();
email = null;
}
if (email != null)
{
if (!packIn.isSuccess()) {