From 1879e6575aaad4851a273349b8eede194e2d2ee2 Mon Sep 17 00:00:00 2001 From: Taylor Otwell Date: Tue, 10 Jul 2012 08:02:08 -0500 Subject: [PATCH] tweak eloquent model change method to not check types. --- laravel/database/eloquent/model.php | 2 +- laravel/documentation/changes.md | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/laravel/database/eloquent/model.php b/laravel/database/eloquent/model.php index 8703f4c4..ccdd42d5 100644 --- a/laravel/database/eloquent/model.php +++ b/laravel/database/eloquent/model.php @@ -502,7 +502,7 @@ abstract class Model { */ public function changed($attribute) { - return array_get($this->attributes, $attribute) !== array_get($this->original, $attribute); + return array_get($this->attributes, $attribute) != array_get($this->original, $attribute); } /** diff --git a/laravel/documentation/changes.md b/laravel/documentation/changes.md index e5c68b89..7fb72d41 100644 --- a/laravel/documentation/changes.md +++ b/laravel/documentation/changes.md @@ -37,6 +37,7 @@ ## Laravel 3.2.4 - Speed up many to many eager loading mapping. +- Tweak the Eloquent::changed() method. ## Upgrading From 3.2.3