Fix duplicate code
This commit is contained in:
parent
79c9745442
commit
a71541e6de
@ -318,16 +318,14 @@ if (empty($reshook)) {
|
|||||||
$error ++;
|
$error ++;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!$error) {
|
if (!$error)
|
||||||
|
{
|
||||||
$object->fetch($id);
|
$object->fetch($id);
|
||||||
|
|
||||||
$object->oldcopy = clone $object;
|
$object->oldcopy = clone $object;
|
||||||
|
|
||||||
if (!$error) {
|
|
||||||
$db->begin();
|
$db->begin();
|
||||||
|
|
||||||
$object->oldcopy = clone $object;
|
|
||||||
|
|
||||||
$object->lastname = GETPOST("lastname", 'alpha');
|
$object->lastname = GETPOST("lastname", 'alpha');
|
||||||
$object->firstname = GETPOST("firstname", 'alpha');
|
$object->firstname = GETPOST("firstname", 'alpha');
|
||||||
$object->login = GETPOST("login", 'alpha');
|
$object->login = GETPOST("login", 'alpha');
|
||||||
@ -490,7 +488,6 @@ if (empty($reshook)) {
|
|||||||
$db->rollback();
|
$db->rollback();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user