public static function setUpBeforeClass() { ParseClient::_unsetStorage(); session_start(); ParseTestHelper::setUp(); self::$parseStorage = ParseClient::getStorage(); }
public function logout(Request $request, Response $response, $args) { $this->logger->info("Login page action dispatched"); $uri = $request->getUri(); try { $this->userRepository->logOut(); $this->currentUser = $this->userRepository->getCurrentUser(); ParseClient::getStorage()->set('company', null); } catch (ParseException $e) { ParseErrorHandler::handleParseError($e); } return $response->withStatus(302)->withHeader('Location', $uri->withPath('login')); }
public function setCurrentCompany($company) { static::$currentCompany = $company; ParseClient::getStorage()->set('company', $company); return; }
/** * Get the ParseClient storage object (if set) or ParseMemoryStorage as default. * * @return ParseMemoryStorage */ public static function Storage() { return ParseClient::getStorage() ?: ParseHelper::MemoryStorage(); }
function __construct($cacheListObjects = false, $chainExecHandler = null, $cacheStorage = null) { $this->cacheStorage = $cacheStorage ?: ParseClient::getStorage() ?: new ParseMemoryStorage(); $this->cacheListObjects = $cacheListObjects; $this->chainExecHandler = $chainExecHandler; }
public static function setUpBeforeClass() { Helper::setUp(); self::$parseStorage = ParseClient::getStorage(); }