Skip to content

Commit

Permalink
Merge pull request #354 from JohnVillalovos/jlvillal/issue_242
Browse files Browse the repository at this point in the history
fix: declare `ReservationControllerResult.requiresApproval`
  • Loading branch information
effgarces authored May 27, 2024
2 parents 5b557b9 + 1545a7b commit a27ce5b
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 1 deletion.
15 changes: 14 additions & 1 deletion WebServices/AuthenticationWebService.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,21 @@
require_once(ROOT_DIR . 'WebServices/Requests/AuthenticationRequest.php');
require_once(ROOT_DIR . 'WebServices/Requests/SignOutRequest.php');

class SignedOutResponse extends RestResponse
{
/**
* @var bool;
*/
public $signedOut;
}


class AuthenticationWebService
{
/**
* @var IRestServer
*/
private $server;
/**
* @var IWebServiceAuthentication
*/
Expand Down Expand Up @@ -71,7 +84,7 @@ public function SignOut()
Log::Debug('WebService SignOut for userId %s and sessionToken %s', $userId, $sessionToken);

$this->authentication->Logout($userId, $sessionToken);
$r = new RestResponse();
$r = new SignedOutResponse();
$r->signedOut = true;
$this->server->WriteResponse($r);
}
Expand Down
4 changes: 4 additions & 0 deletions WebServices/Controllers/ReservationSaveController.php
Original file line number Diff line number Diff line change
Expand Up @@ -288,6 +288,10 @@ class ReservationControllerResult
* @var array|string[]
*/
private $errors = [];
/**
* @var bool
*/
private $requiresApproval;

public function __construct($referenceNumber = null, $errors = [], $requiresApproval = false)
{
Expand Down

0 comments on commit a27ce5b

Please sign in to comment.