I really confuse why the model validation() function is not calling. Code on customers
model as
public function validation()
{
print_r('method called');
// name
$this->validate(new PresenceOf(array(
"field" => "name",
"message" => 'User name is required'
)));
return $this->validationHasFailed() != true;
}
On validation fail, default message name is required
is showing.
I tried with:
php 5.6.11 and 5.6.19
phalcon 2.0.9 and 2.1.0
Any one have any idea?