Browse files

Fix test by checking against an empty array instead of `false`

  • Loading branch information...
1 parent c48afae commit c4f8289b539143b3d112596eb26a8ac6f0086324 @rchavik rchavik committed Dec 27, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/Cake/Model/Behavior/TreeBehavior.php
View
2 lib/Cake/Model/Behavior/TreeBehavior.php
@@ -212,7 +212,7 @@ public function beforeSave(Model $Model, $options = array()) {
'fields' => array($Model->primaryKey, $parent, $left, $right), 'recursive' => $recursive)
);
- if ($values === false) {
+ if (empty($values)) {
return false;
}
list($node) = array_values($values);

0 comments on commit c4f8289

Please sign in to comment.