Elgg\PersistentLoginService::setSession PHP Method

setSession() protected method

Store the token in the session (or remove it from the session)
protected setSession ( string $token ) : void
$token string The token to store in session. Empty string to remove.
return void
    protected function setSession($token)
    {
        if ($token) {
            $this->session->set('code', $token);
        } else {
            $this->session->remove('code');
        }
    }