From 49384514efca7115a50de0861244f7d5f4b9d34f Mon Sep 17 00:00:00 2001 From: Mark Huot Date: Fri, 13 Apr 2012 10:20:34 -0300 Subject: [PATCH] The __get() magic method runs three checks before giving up but the __isset() method only runs two checks. This syncs the logic to ensure that __get() and __isset() are looking at the same possibilities. --- laravel/database/eloquent/model.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/laravel/database/eloquent/model.php b/laravel/database/eloquent/model.php index 4fe8ef86..46fe6c5a 100644 --- a/laravel/database/eloquent/model.php +++ b/laravel/database/eloquent/model.php @@ -650,6 +650,8 @@ abstract class Model { { if (array_key_exists($key, $this->$source)) return true; } + + if (method_exists($this, $key)) return true; } /**