mirror of
https://github.com/nextcloud/server.git
synced 2026-02-20 00:12:30 -05:00
Type the autentication provider passwords as nullable strings
For historic reasons we couldn't add a nullable type hint before nullable type hints were supported by our target php versions. This is now possible. Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
This commit is contained in:
parent
581862b51b
commit
01b8291c76
3 changed files with 4 additions and 13 deletions
|
|
@ -71,21 +71,12 @@ class DefaultTokenProvider implements IProvider {
|
|||
}
|
||||
|
||||
/**
|
||||
* Create and persist a new token
|
||||
*
|
||||
* @param string $token
|
||||
* @param string $uid
|
||||
* @param string $loginName
|
||||
* @param string|null $password
|
||||
* @param string $name
|
||||
* @param int $type token type
|
||||
* @param int $remember whether the session token should be used for remember-me
|
||||
* @return IToken
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function generateToken(string $token,
|
||||
string $uid,
|
||||
string $loginName,
|
||||
$password,
|
||||
?string $password,
|
||||
string $name,
|
||||
int $type = IToken::TEMPORARY_TOKEN,
|
||||
int $remember = IToken::DO_NOT_REMEMBER): IToken {
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ interface IProvider {
|
|||
public function generateToken(string $token,
|
||||
string $uid,
|
||||
string $loginName,
|
||||
$password,
|
||||
?string $password,
|
||||
string $name,
|
||||
int $type = IToken::TEMPORARY_TOKEN,
|
||||
int $remember = IToken::DO_NOT_REMEMBER): IToken;
|
||||
|
|
|
|||
|
|
@ -80,7 +80,7 @@ class PublicKeyTokenProvider implements IProvider {
|
|||
public function generateToken(string $token,
|
||||
string $uid,
|
||||
string $loginName,
|
||||
$password,
|
||||
?string $password,
|
||||
string $name,
|
||||
int $type = IToken::TEMPORARY_TOKEN,
|
||||
int $remember = IToken::DO_NOT_REMEMBER): IToken {
|
||||
|
|
|
|||
Loading…
Reference in a new issue