From 76aa6607b64d50889c77d1bbae88b5a9125e858c Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 23 Oct 2011 13:02:54 +0200 Subject: [PATCH] Fix: Error report when no label provided --- htdocs/contact/fiche.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/contact/fiche.php b/htdocs/contact/fiche.php index 9a44c276e58..f0b77eb66df 100644 --- a/htdocs/contact/fiche.php +++ b/htdocs/contact/fiche.php @@ -154,7 +154,7 @@ if (empty($reshook)) if (! $_POST["name"]) { $error++; $errors[]=$langs->trans("ErrorFieldRequired",$langs->transnoentities("Lastname").' / '.$langs->transnoentities("Label")); - $_GET["action"] = $_POST["action"] = 'create'; + $action = 'create'; } if ($_POST["name"]) @@ -163,7 +163,7 @@ if (empty($reshook)) if ($id <= 0) { $error++; $errors[]=($object->error?array($object->error):$object->errors); - $_GET["action"] = $_POST["action"] = 'create'; + $action = 'create'; } }