Enforce non-empty passwords when editing user settings

This commit is contained in:
Albert Santoni 2014-08-01 15:38:35 -04:00
parent 0203be0f10
commit 1ab30c26e6
1 changed files with 2 additions and 1 deletions

View File

@ -146,7 +146,8 @@ class UserController extends Zend_Controller_Action
// We don't allow 6 x's as a password.
// The reason is because we use that as a password placeholder
// on the client side.
if ($formData['cu_password'] != "xxxxxx") {
if (($formData['cu_password'] != "xxxxxx") &&
(!empty($formData['cu_password'])) {
$user->setPassword($formData['cu_password']);
}
$user->setEmail($formData['cu_email']);