public removePersistentLogin ( ) : void | ||
return | void |
public function removePersistentLogin()
{
if ($this->cookie_token) {
$client_hash = $this->hashToken($this->cookie_token);
$this->removeHash($client_hash);
}
$this->setCookie("");
$this->setSession("");
}
function testRemoveWithoutCookieCantDeleteHash() { $this->dbMock->expects($this->never())->method('deleteData'); $this->svc->removePersistentLogin(); $this->assertSame('', $this->lastCookieSet->value); $this->assertSame($this->thirtyDaysAgo, $this->lastCookieSet->expire); $this->assertNull($this->session->get('code')); }