From 2398f34631bb076d49f6c0c1e7a30ae3b1b6ac79 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mr=C2=B7x?= Date: Tue, 27 Apr 2021 18:35:38 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Database/ActiveRecord.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Database/ActiveRecord.php b/Database/ActiveRecord.php index 18c55f35..fd228f5d 100644 --- a/Database/ActiveRecord.php +++ b/Database/ActiveRecord.php @@ -309,12 +309,12 @@ class ActiveRecord extends BaseActiveRecord $lists = $this->getAnnotation(self::GET); foreach ($lists as $key => $item) { - $data[$key] = $this->{$item}($data[$key] ?? null); + $data[$key] = call_user_func([$this, $item], $data[$key] ?? null); } - $data = array_merge($data, $this->runRelate()); + return array_merge($data, $this->runRelate()); - $class = Snowflake::app()->getChannel(); - $class->push($this, static::class); +// $class = Snowflake::app()->getChannel(); +// $class->push($this, static::class); return $data; }