From ce93e7c20689ae88f7abe36cc2d00066dc43c666 Mon Sep 17 00:00:00 2001 From: euromark Date: Tue, 18 Dec 2012 01:28:05 +0100 Subject: [PATCH] (isset($contain[0]) && $contain[0] === null) always false --- lib/Cake/Model/Behavior/ContainableBehavior.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/Cake/Model/Behavior/ContainableBehavior.php b/lib/Cake/Model/Behavior/ContainableBehavior.php index 92df83695..280da6460 100644 --- a/lib/Cake/Model/Behavior/ContainableBehavior.php +++ b/lib/Cake/Model/Behavior/ContainableBehavior.php @@ -109,9 +109,7 @@ class ContainableBehavior extends ModelBehavior { } $noContain = $noContain && empty($contain); - if ( - $noContain || empty($contain) || (isset($contain[0]) && $contain[0] === null) - ) { + if ($noContain || empty($contain)) { if ($noContain) { $query['recursive'] = -1; }