Return bad late or not status for order

This commit is contained in:
Laurent Destailleur 2016-02-09 14:29:12 +01:00
parent 50eae967bc
commit 223195538a

View File

@ -3342,14 +3342,14 @@ class Commande extends CommonOrder
/**
* Is the customer order delayed?
*
* @return bool
* @return bool true if late, false if not
*/
public function hasDelay()
{
global $conf;
if (!($this->statut > Commande::STATUS_DRAFT) && ($this->statut < Commande::STATUS_CLOSED)) {
return false;
if (! ($this->statut > Commande::STATUS_DRAFT && $this->statut < Commande::STATUS_CLOSED)) {
return false; // Never late if not inside this status range
}
$now = dol_now();