From: Roland Häder Date: Sat, 5 Nov 2022 05:02:03 +0000 (+0100) Subject: Continued: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=b640d403d804bf9a66962ac4c94bc4a566df473f;p=jcontacts-business-core.git Continued: - ops, wrong indenting - also closed internal TODO as above getClass() check is enough --- diff --git a/src/org/mxchange/jcontactsbusiness/model/branchoffice/BusinessBranchOffice.java b/src/org/mxchange/jcontactsbusiness/model/branchoffice/BusinessBranchOffice.java index fa105bf..3ebf5e5 100644 --- a/src/org/mxchange/jcontactsbusiness/model/branchoffice/BusinessBranchOffice.java +++ b/src/org/mxchange/jcontactsbusiness/model/branchoffice/BusinessBranchOffice.java @@ -325,7 +325,6 @@ public class BusinessBranchOffice implements BranchOffice { // Init comparisons final int[] comparators = { - // First compare basic data // First compare basic data this.getBranchCompany().compareTo(branchOffice.getBranchCompany()), // ... branch office number @@ -371,7 +370,7 @@ public class BusinessBranchOffice implements BranchOffice { return false; } - // @todo Maybe a bit unsafe cast? + // Cast to BranchOffice interface final BranchOffice branchOffice = (BranchOffice) object; if (!Objects.equals(this.getBranchCity(), branchOffice.getBranchCity())) { diff --git a/src/org/mxchange/jcontactsbusiness/model/department/BusinessDepartment.java b/src/org/mxchange/jcontactsbusiness/model/department/BusinessDepartment.java index 406a6d2..66fea63 100644 --- a/src/org/mxchange/jcontactsbusiness/model/department/BusinessDepartment.java +++ b/src/org/mxchange/jcontactsbusiness/model/department/BusinessDepartment.java @@ -196,7 +196,7 @@ public class BusinessDepartment implements Department { // ... lead contact ContactUtils.compare(this.getDepartmentLead(), department.getDepartmentLead()), // ... user owner -UserUtils.compare(this.getDepartmentUserOwner(), department.getDepartmentUserOwner()) + UserUtils.compare(this.getDepartmentUserOwner(), department.getDepartmentUserOwner()) }; // Check all values