Bug Report #4415

[Validation] Anonymous function doesnt stop check execution

Added by Ivan Brotkin almost 3 years ago.

Status:NewStart date:01/23/2012
Priority:NormalDue date:
Assignee:-% Done:

0%

Category:Core
Target version:-
Resolution: Points:1

Description

I have a Validation object with two rules:

$valid->rules('foo',
array(function($value) {...})),
array('Valid::not_empty')
);

Expected behavior: if first rule triggers error, execution stopped. But the second one runs anyway, and its error will override my closure message.

I will send pull request for it later.

Also available in: Atom PDF