removed return values
This commit is contained in:
parent
c10ad18c5a
commit
44e5b0b6e7
|
@ -66,7 +66,7 @@ class CsrfTokenManager implements CsrfTokenManagerInterface
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
public function getToken($tokenId)
|
public function getToken(string $tokenId)
|
||||||
{
|
{
|
||||||
$namespacedId = $this->getNamespace().$tokenId;
|
$namespacedId = $this->getNamespace().$tokenId;
|
||||||
if ($this->storage->hasToken($namespacedId)) {
|
if ($this->storage->hasToken($namespacedId)) {
|
||||||
|
@ -83,7 +83,7 @@ class CsrfTokenManager implements CsrfTokenManagerInterface
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
public function refreshToken($tokenId)
|
public function refreshToken(string $tokenId)
|
||||||
{
|
{
|
||||||
$namespacedId = $this->getNamespace().$tokenId;
|
$namespacedId = $this->getNamespace().$tokenId;
|
||||||
$value = $this->generator->generateToken();
|
$value = $this->generator->generateToken();
|
||||||
|
@ -96,7 +96,7 @@ class CsrfTokenManager implements CsrfTokenManagerInterface
|
||||||
/**
|
/**
|
||||||
* {@inheritdoc}
|
* {@inheritdoc}
|
||||||
*/
|
*/
|
||||||
public function removeToken($tokenId)
|
public function removeToken(string $tokenId)
|
||||||
{
|
{
|
||||||
return $this->storage->removeToken($this->getNamespace().$tokenId);
|
return $this->storage->removeToken($this->getNamespace().$tokenId);
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,7 +30,7 @@ interface CsrfTokenManagerInterface
|
||||||
*
|
*
|
||||||
* @return CsrfToken The CSRF token
|
* @return CsrfToken The CSRF token
|
||||||
*/
|
*/
|
||||||
public function getToken($tokenId);
|
public function getToken(string $tokenId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Generates a new token value for the given ID.
|
* Generates a new token value for the given ID.
|
||||||
|
@ -44,7 +44,7 @@ interface CsrfTokenManagerInterface
|
||||||
*
|
*
|
||||||
* @return CsrfToken The CSRF token
|
* @return CsrfToken The CSRF token
|
||||||
*/
|
*/
|
||||||
public function refreshToken($tokenId);
|
public function refreshToken(string $tokenId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Invalidates the CSRF token with the given ID, if one exists.
|
* Invalidates the CSRF token with the given ID, if one exists.
|
||||||
|
@ -54,7 +54,7 @@ interface CsrfTokenManagerInterface
|
||||||
* @return string|null Returns the removed token value if one existed, NULL
|
* @return string|null Returns the removed token value if one existed, NULL
|
||||||
* otherwise
|
* otherwise
|
||||||
*/
|
*/
|
||||||
public function removeToken($tokenId);
|
public function removeToken(string $tokenId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns whether the given CSRF token is valid.
|
* Returns whether the given CSRF token is valid.
|
||||||
|
|
Reference in New Issue