diff --git a/htdocs/websites/index.php b/htdocs/websites/index.php index f763c8dd39b..0d4763f5dc3 100644 --- a/htdocs/websites/index.php +++ b/htdocs/websites/index.php @@ -169,7 +169,7 @@ if ($action == 'addsite') { $db->begin(); - if (! $error && empty(GETPOST('WEBSITE_REF','alpha'))) + if (! $error && ! GETPOST('WEBSITE_REF','alpha')) { $error++; setEventMessages($langs->transnoentities("ErrorFieldRequired", $langs->transnoentities("Ref")), null, 'errors');