From 96d9a0307cba8682d9be17b0a8520ad5ff3e2f21 Mon Sep 17 00:00:00 2001 From: Arsen Mirzaev Tatyano-Muradovich Date: Mon, 16 Aug 2021 04:12:22 +1000 Subject: [PATCH] =?UTF-8?q?=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BE=D0=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mirzaev/skillparts/system/controllers/ProfileController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mirzaev/skillparts/system/controllers/ProfileController.php b/mirzaev/skillparts/system/controllers/ProfileController.php index 3ef206a..c9be47b 100644 --- a/mirzaev/skillparts/system/controllers/ProfileController.php +++ b/mirzaev/skillparts/system/controllers/ProfileController.php @@ -544,7 +544,7 @@ class ProfileController extends Controller } // Запись в буфер данных о типе геолокации - $account->geol = ['type' => 'ip'] + $account->geol; + $account->geol = ['type' => 'ip'] + ($account->geol ?? []); self::syncGeolocationWithDellin($account); } @@ -733,7 +733,7 @@ class ProfileController extends Controller } // Синхронизация с базой данных (таблица с ДеловыеЛинии) - if ($dellin = Dellin::searchByCityKladr(str_pad($account->geol['data']['city_kladr_id'], 25, '0000000000000000000000'))) { + if (isset($account->geol['data']) && $dellin = Dellin::searchByCityKladr(str_pad($account->geol['data']['city_kladr_id'], 25, '0000000000000000000000'))) { // Удалось найти город с терминалами ДеловыеЛинии foreach ($dellin['data']['terminals']['terminal'] as $dellin) {