mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 11:28:25 +00:00
Fixes #2982, TreeBehavior::verify, non-portable SQL, badly quoted conditions
git-svn-id: https://svn.cakephp.org/repo/branches/1.2.x.x@5806 3807eeeb-6ff5-0310-8944-8be069107fe0
This commit is contained in:
parent
aba86fe522
commit
7ebb27fccc
3 changed files with 3 additions and 4 deletions
|
@ -599,7 +599,7 @@ class TreeBehavior extends ModelBehavior {
|
|||
$errors[] = array('node', $instance[$model->name][$model->primaryKey],
|
||||
'right greater than parent (node ' . $instance['VerifyParent'][$model->primaryKey] . ').');
|
||||
}
|
||||
} elseif ($model->findCount(array($scope, $left => '< ' . $instance[$model->name][$left], $right => '> ' . $instance[$model->name][$right]))) {
|
||||
} elseif ($model->findCount(array($scope, $left . '< ' . $instance[$model->name][$left], $right . '> ' . $instance[$model->name][$right]))) {
|
||||
$errors[] = array('node', $instance[$model->name][$model->primaryKey], 'The parent field is blank, but has a parent');
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2859,7 +2859,6 @@ class ModelTest extends CakeTestCase {
|
|||
$data = array();
|
||||
$expected = $this->model->save($data);
|
||||
$this->assertFalse($expected);
|
||||
|
||||
}
|
||||
|
||||
/*function testBasicValidation() {
|
||||
|
|
Loading…
Reference in a new issue