function applyLoginResult($loginResult)
 {
     $this->host = parse_url($loginResult->serverUrl, PHP_URL_HOST);
     $port = parse_url($loginResult->serverUrl, PHP_URL_PORT);
     $this->host .= !empty($port) ? ":{$port}" : "";
     $this->sessionId = crypto_serialize($loginResult->sessionId);
 }
Ejemplo n.º 2
0
 /**
  * Redeems the result (or exception) after async processing has completed.
  *
  * @param $result
  */
 function redeem($result)
 {
     verifyCallingFromCLI();
     $this->result = $result;
     redis()->rpush(self::RESULT . $this->asyncId, crypto_serialize($this->result));
 }