protected function PasswordConfirm::prepareElementValidateCallbacks in Webform 6.x
Same name and namespace in other branches
- 8.5 src/Plugin/WebformElement/PasswordConfirm.php \Drupal\webform\Plugin\WebformElement\PasswordConfirm::prepareElementValidateCallbacks()
Prepare an element's validation callbacks.
Parameters
array $element: An element.
\Drupal\webform\WebformSubmissionInterface $webform_submission: A webform submission.
Overrides WebformElementBase::prepareElementValidateCallbacks
File
- src/
Plugin/ WebformElement/ PasswordConfirm.php, line 44
Class
- PasswordConfirm
- Provides a 'password_confirm' element.
Namespace
Drupal\webform\Plugin\WebformElementCode
protected function prepareElementValidateCallbacks(array &$element, WebformSubmissionInterface $webform_submission = NULL) {
parent::prepareElementValidateCallbacks($element, $webform_submission);
$element['#element_validate'][] = [
get_class($this),
'validatePasswordConfirm',
];
}