function cas_validation_constraint_alter in CAS 8
Same name and namespace in other branches
- 2.x cas.module \cas_validation_constraint_alter()
Implements hook_validation_constraint_alter().
Replace core's ProtectedUserFieldConstraint with a decorated version that skips over the validation if restricted password mangement is enabled.
File
- ./
cas.module, line 268 - Provides CAS authentication for Drupal.
Code
function cas_validation_constraint_alter(array &$definitions) {
$definitions['ProtectedUserField']['class'] = 'Drupal\\cas\\Plugin\\Validation\\Constraint\\CasProtectedUserFieldConstraint';
}