Skip to content

Commit c721c22

Browse files
committed
#16337 - Adjust Validation:validate() signature
1 parent 6de92b9 commit c721c22

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

phalcon/Filter/Validation.zep

+3-1
Original file line numberDiff line numberDiff line change
@@ -478,8 +478,10 @@ class Validation extends Injectable implements ValidationInterface
478478
*
479479
* @param array|object data
480480
* @param object entity
481+
*
482+
* @return Messages|false
481483
*/
482-
public function validate(var data = null, var entity = null) -> <Messages>
484+
public function validate(var data = null, var entity = null) -> <Messages> | false
483485
{
484486
var combinedFieldsValidators, field, messages, scope, status, validator,
485487
validatorData, validators;

phalcon/Filter/Validation/ValidationInterface.zep

+3-1
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,8 @@ interface ValidationInterface
103103
*
104104
* @param array|object data
105105
* @param object entity
106+
*
107+
* @return Messages|false
106108
*/
107-
public function validate(var data = null, var entity = null) -> <Messages>;
109+
public function validate(var data = null, var entity = null) -> <Messages> | false;
108110
}

0 commit comments

Comments
 (0)