Merge pull request #3369 from marcosgdf/minor
Fixed minor problem with error alert when creating user
This commit is contained in:
commit
7d18adebb1
@ -255,7 +255,7 @@ if ($action == 'add' && $canadduser)
|
||||
$langs->load("errors");
|
||||
$db->rollback();
|
||||
if (is_array($object->errors) && count($object->errors)) setEventMessage($object->errors,'errors');
|
||||
else setEventMessage($object->error);
|
||||
else setEventMessage($object->error, 'errors');
|
||||
$action="create"; // Go back to create page
|
||||
}
|
||||
|
||||
@ -320,7 +320,7 @@ if ($action == 'update' && ! $_POST["cancel"])
|
||||
$result=$tmpuser->fetch(0, GETPOST("login"));
|
||||
if ($result > 0)
|
||||
{
|
||||
setEventMessage($langs->trans("ErrorLoginAlreadyExists"), 'errors');
|
||||
setEventMessage($langs->trans("ErrorLoginAlreadyExists", GETPOST('login')), 'errors');
|
||||
$action="edit"; // Go back to create page
|
||||
$error++;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user