]> git.mxchange.org Git - pizzaservice-ejb.git/commitdiff
Please cherry-pick:
authorRoland Häder <roland@mxchange.org>
Fri, 21 Dec 2018 18:56:25 +0000 (19:56 +0100)
committerRoland Häder <roland@mxchange.org>
Fri, 19 Jul 2019 21:19:12 +0000 (23:19 +0200)
- parameter of this exception has changed, needs to be direct company (short)
  name now, not full BasicData instance

Signed-off-by: Roland Häder <roland@mxchange.org>
src/java/org/mxchange/jcontactsbusiness/model/basicdata/PizzaAdminBusinessDataSessionBean.java

index 9139d7a9802e889ee9c3ebf3bf1a5e83833d2f64..277cac92bd52e36c1a091d18eb3723b76731ea6f 100644 (file)
@@ -75,13 +75,13 @@ public class PizzaAdminBusinessDataSessionBean extends BasePizzaEnterpriseBean i
                        throw new IllegalArgumentException("basicData.companyShortName is empty"); //NOI18N
                } else if (this.isSameCompanyShortNameAdded(basicData)) {
                        // Throw exception
-                       throw new BasicDataAlreadyAddedException(basicData);
+                       throw new BasicDataAlreadyAddedException(basicData.getCompanyShortName());
                } else if ((basicData.getCompanyName() != null) && (basicData.getCompanyName().isEmpty())) {
                        // Should not be empty string when set
                        throw new IllegalArgumentException("basicData.companyName is empty"); //NOI18N
                } else if ((basicData.getCompanyName() != null) && (this.isSameCompanyNameAdded(basicData))) {
                        // Throw exception
-                       throw new BasicDataAlreadyAddedException(basicData);
+                       throw new BasicDataAlreadyAddedException(basicData.getCompanyName());
                }
 
                // Now add current date