From 3e47532e07fcfca9f400ce5d6989c0bb0e45d7fe Mon Sep 17 00:00:00 2001 From: romanb Date: Sat, 1 Sep 2007 20:20:17 +0000 Subject: [PATCH] Notnull validator no longer checks for empty strings --- lib/Doctrine/Validator/Notnull.php | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/lib/Doctrine/Validator/Notnull.php b/lib/Doctrine/Validator/Notnull.php index 2ceb11a08..b7b131c95 100644 --- a/lib/Doctrine/Validator/Notnull.php +++ b/lib/Doctrine/Validator/Notnull.php @@ -40,9 +40,6 @@ class Doctrine_Validator_Notnull */ public function validate(Doctrine_Record $record, $key, $value) { - if ($value === null || $value === '') { - return false; - } - return true; + return !is_null($value); } }