Update card.php

This commit is contained in:
Laurent Destailleur
2018-03-11 00:05:32 +01:00
committed by GitHub
parent c2397fad60
commit 03f7df88c6

View File

@@ -292,12 +292,15 @@ if (empty($reshook))
// Fill array 'array_options' with data from update form
$extralabels = $extrafields->fetch_name_optionals_label($object->table_element);
$ret = $extrafields->setOptionalsFromPost($extralabels, $object, GETPOST('attribute'));
if ($ret < 0) $error++;
if ($ret < 0) { $error++; }
if (! $error)
{
$result = $object->insertExtraFields();
if ($result < 0) $errors = $object->errors;
if ($result < 0)
{
$error++;
$errors = $object->errors;
}
}
if ($error) $action = 'edit_extras';
}