From 37b3ad143402945c38ebcee646eec92135d866f0 Mon Sep 17 00:00:00 2001 From: zYne Date: Fri, 25 Aug 2006 15:21:23 +0000 Subject: [PATCH] Fixed Doctrine_Record::exists() and removed final attribute since its *not* a method that is used by Doctrine internally --- Doctrine/Record.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Doctrine/Record.php b/Doctrine/Record.php index bb0b14d57..4c961ca2a 100644 --- a/Doctrine/Record.php +++ b/Doctrine/Record.php @@ -824,8 +824,9 @@ abstract class Doctrine_Record extends Doctrine_Access implements Countable, Ite * checks if record has data * @return boolean */ - final public function exists() { - return $this->state !== Doctrine_Record::STATE_TCLEAN; + public function exists() { + return ($this->state !== Doctrine_Record::STATE_TCLEAN && + $this->state !== Doctrine_Record::STATE_TDIRTY); } /** * method for checking existence of properties and Doctrine_Record references