From 622f53e401c9c5983a540e47ffb65cb741ae004c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Simon=20Pocrnji=C4=8D?= Date: Thu, 18 Dec 2025 18:25:15 +0100 Subject: [PATCH] removed something --- app/Services/ImportProcessor.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/app/Services/ImportProcessor.php b/app/Services/ImportProcessor.php index de5ca07..8bb6aad 100644 --- a/app/Services/ImportProcessor.php +++ b/app/Services/ImportProcessor.php @@ -3112,17 +3112,17 @@ private function upsertAddress(int $personId, array $addrData, $mappings): array $addressLine = preg_replace('/\s*([,;\/])\s*/', '$1 ', $addressLine); $addressLine = trim($addressLine); // Skip common placeholders or missing values - if ($addressLine === '' || $addressLine === '0' || strcasecmp($addressLine, '#N/A') === 0 || preg_match('/^(#?n\/?a|na|null|none)$/i', $addressLine)) { + if ($addressLine === '' || $addressLine === '0' || preg_match('/^(#?n\/?a|na|null|none)$/i', $addressLine)) { return ['action' => 'skipped', 'message' => 'No address value']; } if (mb_strlen($addressLine) < 3) { return ['action' => 'skipped', 'message' => 'Invalid address value']; } // If identical address already exists anywhere, skip to avoid constraint violation - $existingAny = PersonAddress::where('address', $addressLine)->first(); + /*$existingAny = PersonAddress::where('address', $addressLine)->first(); if ($existingAny) { return ['action' => 'skipped', 'message' => 'Address already exists in database']; - } + }*/ // Default country SLO if not provided if (! isset($addrData['country']) || $addrData['country'] === null || $addrData['country'] === '') { $addrData['country'] = 'SLO';