chg: [inboxProcessors] Change deprecated `notEmpty` to `notEmptyString`
parent
a78864912e
commit
04bd67e082
|
@ -159,9 +159,9 @@ class LocalToolInboxProcessor extends GenericInboxProcessor
|
|||
{
|
||||
return $validator
|
||||
->requirePresence('connectorName')
|
||||
->notEmpty('connectorName', 'The connector name must be provided')
|
||||
->notEmptyString('connectorName', 'The connector name must be provided')
|
||||
->requirePresence('cerebrateURL')
|
||||
->notEmpty('cerebrateURL', 'A url must be provided')
|
||||
->notEmptyString('cerebrateURL', 'A url must be provided')
|
||||
->requirePresence('local_tool_id')
|
||||
->numeric('local_tool_id', 'A local_tool_id must be provided')
|
||||
->requirePresence('remote_tool_id')
|
||||
|
|
|
@ -37,13 +37,13 @@ class RegistrationProcessor extends UserInboxProcessor implements GenericInboxPr
|
|||
protected function addValidatorRules($validator)
|
||||
{
|
||||
return $validator
|
||||
->notEmpty('username', 'A username must be provided.')
|
||||
->notEmptyString('username', 'A username must be provided.')
|
||||
->add('email', 'validFormat', [
|
||||
'rule' => 'email',
|
||||
'message' => 'E-mail must be valid'
|
||||
])
|
||||
->notEmpty('first_name', 'A first name must be provided')
|
||||
->notEmpty('last_name', 'A last name must be provided')
|
||||
->notEmptyString('first_name', 'A first name must be provided')
|
||||
->notEmptyString('last_name', 'A last name must be provided')
|
||||
->add('password', 'password_complexity', [
|
||||
'rule' => function($value, $context) {
|
||||
if (!preg_match('/^((?=.*\d)|(?=.*\W+))(?![\n])(?=.*[A-Z])(?=.*[a-z]).*$|.{16,}/s', $value) || strlen($value) < 12) {
|
||||
|
|
Loading…
Reference in New Issue