From 0f80cbac1ccd787ae7694757ca7d5c9a27213d2d Mon Sep 17 00:00:00 2001 From: Stefano Mtangoo Date: Thu, 10 Oct 2024 15:27:53 +0300 Subject: [PATCH] Fix: some files were not saved before previous commit --- Behaviors/GeometryBehavior.php | 3 +++ Behaviors/StBufferBehavior.php | 2 +- Db/PostgisQueryTrait.php | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Behaviors/GeometryBehavior.php b/Behaviors/GeometryBehavior.php index de8095d..069c225 100644 --- a/Behaviors/GeometryBehavior.php +++ b/Behaviors/GeometryBehavior.php @@ -149,6 +149,9 @@ public function afterSave() */ public function afterFind() { + if (empty($this->owner->{$this->attribute})) { + return parent::afterFind(); + } if (!is_object(json_decode($this->owner->{$this->attribute}))) { diff --git a/Behaviors/StBufferBehavior.php b/Behaviors/StBufferBehavior.php index ad0cc7f..ddb59f2 100644 --- a/Behaviors/StBufferBehavior.php +++ b/Behaviors/StBufferBehavior.php @@ -4,7 +4,7 @@ use yii\base\Behavior; use yii\db\ActiveRecord; -use Yii2\Extension\Postgis\components\StBuffer; +use Yii2\Extension\Postgis\Components\StBuffer; /** * Class StBufferBehavior diff --git a/Db/PostgisQueryTrait.php b/Db/PostgisQueryTrait.php index fdac74f..5be8a97 100644 --- a/Db/PostgisQueryTrait.php +++ b/Db/PostgisQueryTrait.php @@ -1,6 +1,6 @@ */ trait PostgisQueryTrait