This commit is contained in:
xdrm-brackets 2017-02-21 09:28:36 +01:00
parent d4c06aa1b7
commit ce92299fea
1 changed files with 3 additions and 2 deletions

View File

@ -650,9 +650,10 @@
/* [0] Vérification du token /* [0] Vérification du token
=========================================================*/ =========================================================*/
$checkToken = new Repo('machine/checkToken', [ $_SESSION['WAREHOUSE']['id'], $token, $renew ]); $checkToken = new Repo('machine/checkToken', [ $_SESSION['WAREHOUSE']['id'], $token, $renew ]);
$machine = $checkToken->answer();
// Si token incorrect, on envoie une erreur // Si token incorrect, on envoie une erreur
if( !$checkToken->answer() ) if( $machine === false )
return [ 'error' => new Error(Err::TokenError) ]; return [ 'error' => new Error(Err::TokenError) ];
@ -697,7 +698,7 @@
=========================================================*/ =========================================================*/
/* (1) Basic working data update /* (1) Basic working data update
---------------------------------------------------------*/ ---------------------------------------------------------*/
$basis_update = self::getMachineWorkingInformation($id_machine); $basis_update = self::getMachineWorkingInformation($machine['id_machine']);