Fix bug in operators

feature/formhandler
Sven Slootweg 11 years ago
parent 57b11d4c58
commit 5c6445a023

@ -41,9 +41,9 @@ class CPHPFormValidatorPromiseBaseClass
public function StartResolve() public function StartResolve()
{ {
/* Back and forth! */ /* Back and forth! */
if(is_null($this->previous) === true) if($this->previous == $this->handler)
{ {
$this->next->ContinueResolve(array()); $this->ContinueResolve(array());
} }
else else
{ {
@ -209,7 +209,7 @@ class CPHPFormValidatorOperatorEither extends CPHPFormValidatorOperator
$exceptions = array(); $exceptions = array();
foreach($this->children as $child) foreach($this->children as $child)
{ {
$result = $child->Resolve(); $result = $child->Resolve($exceptions);
if(is_null($result) === false) if(is_null($result) === false)
{ {
$exceptions[] = $result; $exceptions[] = $result;
@ -239,7 +239,7 @@ class CPHPFormValidatorOperatorAll extends CPHPFormValidatorOperator
$exceptions = array(); $exceptions = array();
foreach($this->children as $child) foreach($this->children as $child)
{ {
$result = $child->Resolve($results); $result = $child->Resolve($exceptions);
if(is_null($result) === false) if(is_null($result) === false)
{ {
$exceptions[] = $result; $exceptions[] = $result;

Loading…
Cancel
Save