diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index f8baa72d4cc..a75fd5aa28f 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -2033,8 +2033,11 @@ class Form { $opt.= ' - '.$langs->trans("Stock").':'.$objp->stock; - if ($objp->stock > 0) $outval.= ''.' - '.$langs->transnoentities("Stock").':'.$objp->stock.''; - else if ($objp->stock <= 0) $outval.= ''.' - '.$langs->transnoentities("Stock").':'.$objp->stock.''; + if ($objp->stock > 0) { + $outval.= ' - '.$langs->transnoentities("Stock").':'.$objp->stock.''; + }elseif ($objp->stock <= 0) { + $outval.= ' - '.$langs->transnoentities("Stock").':'.$objp->stock.''; + } } if ($outdurationvalue && $outdurationunit)