From 3a55a861f3bcd49fe9bd0bd06bd38cf895109f03 Mon Sep 17 00:00:00 2001 From: Timotheus Pokorra Date: Tue, 8 Oct 2024 08:47:02 +0200 Subject: [PATCH] small fixes --- .../hsadminng/hs/migration/BaseOfficeDataImport.java | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/test/java/net/hostsharing/hsadminng/hs/migration/BaseOfficeDataImport.java b/src/test/java/net/hostsharing/hsadminng/hs/migration/BaseOfficeDataImport.java index 05213bc5..705f1280 100644 --- a/src/test/java/net/hostsharing/hsadminng/hs/migration/BaseOfficeDataImport.java +++ b/src/test/java/net/hostsharing/hsadminng/hs/migration/BaseOfficeDataImport.java @@ -1129,9 +1129,13 @@ public abstract class BaseOfficeDataImport extends CsvDataImport { || tradeName.toLowerCase().contains("stichting") || tradeName.toLowerCase().contains("foundation") || tradeName.toLowerCase().contains("schule") - || tradeName.toLowerCase().contains("Landkreis") - || tradeName.toLowerCase().contains("Behörde") - || tradeName.toLowerCase().contains("Bezirksamt") + || tradeName.toLowerCase().contains("verein") + || tradeName.toLowerCase().contains("gewerkschaft") + || tradeName.toLowerCase().contains("gesellschaft") + || tradeName.toLowerCase().contains("landkreis") + || tradeName.toLowerCase().contains("behörde") + || tradeName.toLowerCase().contains("bundesamt") + || tradeName.toLowerCase().contains("bezirksamt") ) { return HsOfficePersonType.LEGAL_PERSON; // Haftungsbeschränkt } else if (roles.contains("contractual") && !roles.contains("partner") && @@ -1156,7 +1160,7 @@ public abstract class BaseOfficeDataImport extends CsvDataImport { private static boolean containsWord(final String value, final String... endings) { final var lowerCaseValue = value.toLowerCase(); for (String ending : endings) { - if (lowerCaseValue.isEqualTo(ending.toLowerCase()) || + if (lowerCaseValue.equals(ending.toLowerCase()) || lowerCaseValue.startsWith(ending.toLowerCase() + " ") || lowerCaseValue.contains(" " + ending.toLowerCase() + " ") || lowerCaseValue.endsWith(" " + ending.toLowerCase())) {