Change HTTP response code when nothing modified
This commit is contained in:
parent
73fe991aed
commit
182fe4a90f
@ -490,7 +490,7 @@ class Orders extends DolibarrApi
|
|||||||
throw new RestException(500, 'Error nothing done. May be object is already validated');
|
throw new RestException(500, 'Error nothing done. May be object is already validated');
|
||||||
}
|
}
|
||||||
if ($result < 0) {
|
if ($result < 0) {
|
||||||
throw new RestException(500, 'Error when validating Order: '.$this->commande->error);
|
throw new RestException(304, 'Error when validating Order: '.$this->commande->error);
|
||||||
}
|
}
|
||||||
$result = $this->commande->fetch($id);
|
$result = $this->commande->fetch($id);
|
||||||
if( ! $result ) {
|
if( ! $result ) {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user