From f0ccf4ccd8bdbeb72a13ce3841ba3c5f6933a601 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Roland=20H=C3=A4der?= Date: Tue, 26 Apr 2016 15:36:55 +0200 Subject: [PATCH] catch newly thrown exception --- .../beans/customer/PizzaAdminCustomerWebRequestBean.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/java/org/mxchange/pizzaapplication/beans/customer/PizzaAdminCustomerWebRequestBean.java b/src/java/org/mxchange/pizzaapplication/beans/customer/PizzaAdminCustomerWebRequestBean.java index d643aaff..2a7a49b1 100644 --- a/src/java/org/mxchange/pizzaapplication/beans/customer/PizzaAdminCustomerWebRequestBean.java +++ b/src/java/org/mxchange/pizzaapplication/beans/customer/PizzaAdminCustomerWebRequestBean.java @@ -30,6 +30,7 @@ import javax.naming.InitialContext; import javax.naming.NamingException; import org.mxchange.jcontacts.contact.Contact; import org.mxchange.jcontacts.contact.gender.Gender; +import org.mxchange.jcontacts.exceptions.ContactAlreadyAddedException; import org.mxchange.jcustomercore.events.AdminAddedCustomerEvent; import org.mxchange.jcustomercore.events.CustomerAdminAddedEvent; import org.mxchange.jcustomercore.exceptions.CustomerAlreadyRegisteredException; @@ -115,7 +116,7 @@ public class PizzaAdminCustomerWebRequestBean implements PizzaAdminCustomerWebRe try { // Add customer and return updated updatedCustomer = this.adminCustomerBean.addCustomer(customer); - } catch (final CustomerAlreadyRegisteredException ex) { + } catch (final CustomerAlreadyRegisteredException | ContactAlreadyAddedException ex) { // Throw again throw new FaceletException(ex); } -- 2.39.5