From c5731c81f13cd88954c5df52f6168d908cc61b80 Mon Sep 17 00:00:00 2001 From: thinkphp Date: Wed, 18 Oct 2017 19:14:21 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=E6=A8=A1=E5=9E=8B=E7=B1=BB?= =?UTF-8?q?=E7=9A=84append=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- library/think/Model.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/think/Model.php b/library/think/Model.php index 6725c4c5..05d56f95 100644 --- a/library/think/Model.php +++ b/library/think/Model.php @@ -839,7 +839,7 @@ abstract class Model implements \JsonSerializable, \ArrayAccess if (isset($this->data[$key])) { throw new Exception('bind attr has exists:' . $key); } else { - $item[$key] = $value ? $value->$attr : null; + $item[$key] = $value ? $value->getAttr($attr) : null; } } continue;