]> git.mxchange.org Git - jfinancials-war.git/commitdiff
Please cherry-pick:
authorRoland Häder <roland@mxchange.org>
Fri, 21 Dec 2018 14:28:01 +0000 (15:28 +0100)
committerRoland Häder <roland@mxchange.org>
Fri, 21 Dec 2018 14:28:01 +0000 (15:28 +0100)
- companyName might be set, let's make sure it is not empty
- basicData can be final here

Signed-off-by: Roland Häder <roland@mxchange.org>
src/java/org/mxchange/jfinancials/beans/business/basicdata/FinancialsAdminBasicDataWebRequestBean.java

index 74813183f84eb49ffd3793a19828b7315eb16a19..636c75baf2a8348143ede992640628a18bb95ba9 100644 (file)
@@ -166,10 +166,13 @@ public class FinancialsAdminBasicDataWebRequestBean extends BaseFinancialsBean i
                } else if (this.getCompanyShortName().isEmpty()) {
                        // Is null
                        throw new IllegalArgumentException("this.companyShortName is empty"); //NOI18N
+               } else if ((this.getCompanyName() != null) && (this.getCompanyName().isEmpty())) {
+                       // Is null
+                       throw new IllegalArgumentException("this.companyName is set empty"); //NOI18N
                }
 
                // Prepare entity
-               BasicData basicData = new BusinessBasicData(this.getCompanyShortName());
+               final BasicData basicData = new BusinessBasicData(this.getCompanyShortName());
 
                // Set all opther remaining data
                basicData.setCompanyComments(this.getCompanyComments());