add password hash to user entity
This commit is contained in:
parent
5093259063
commit
016e98412b
1 changed files with 6 additions and 0 deletions
|
|
@ -9,6 +9,7 @@ class User
|
|||
public function __construct(
|
||||
private int $id,
|
||||
private EmailAddress $email,
|
||||
private string $passwordHash = '',
|
||||
private bool $isAdmin = false,
|
||||
) {}
|
||||
|
||||
|
|
@ -22,6 +23,11 @@ class User
|
|||
return $this->email;
|
||||
}
|
||||
|
||||
public function getPasswordHash(): string
|
||||
{
|
||||
return $this->passwordHash;
|
||||
}
|
||||
|
||||
public function isAdmin(): bool
|
||||
{
|
||||
return $this->isAdmin;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue