// now, check validity
if ($value !== null && $value != '') {
- $this->validate($key, $value, $values);
+ if ($key !== 'mdp_adh') {
+ $this->validate($key, $value, $values);
+ }
} elseif (empty($this->_id)) {
//ensure login and password are not empty
if (($key == 'login_adh' || $key == 'mdp_adh') && !isset($required[$key])) {
}
}
+ //password checks need data to be previously set
+ if (isset($values['mdp_adh'])) {
+ $this->validate('mdp_adh', $values['mdp_adh'], $values);
+ }
+
// missing required fields?
foreach ($required as $key => $val) {
$prop = '_' . $this->fields[$key]['propname'];