Update api_orders.class.php

This commit is contained in:
Laurent Destailleur 2017-11-14 01:19:04 +01:00 committed by GitHub
parent d2a67e152b
commit bf05a0b8e0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -414,7 +414,7 @@ class Orders extends DolibarrApi
} }
// Update availability // Update availability
if( isset($this->commande->availability_id) && !empty($this->commande->availability_id) ) { if (!empty($this->commande->availability_id)) {
if ($this->commande->availability($this->commande->availability_id) < 0) if ($this->commande->availability($this->commande->availability_id) < 0)
throw new RestException(400, 'Error while updating availability'); throw new RestException(400, 'Error while updating availability');
} }