Compare commits
3 Commits
142509e9f6
...
61db8fcc95
| Author | SHA1 | Date | |
|---|---|---|---|
| 61db8fcc95 | |||
| 6ddf358f41 | |||
| 33ff1b5b8c |
@ -10,7 +10,7 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"mcnd/ulmus": "dev-master"
|
||||
"mcnd/ulmus": "^1.0 || ^2.0"
|
||||
},
|
||||
"repositories": [
|
||||
{
|
||||
|
||||
@ -80,9 +80,13 @@ abstract class User implements UserInterface {
|
||||
return password_verify($password, $this->password ?? null);
|
||||
}
|
||||
|
||||
public function fullName() : string
|
||||
public function fullname(bool $reverse = false) : string
|
||||
{
|
||||
return trim( ( $this->firstName ?? "" ) . " " . ( $this->lastName ?? "" ) );
|
||||
if (! $this->isLoaded() ) {
|
||||
return "???";
|
||||
}
|
||||
|
||||
return trim($reverse ? "{$this->lastName}, {$this->firstName}" : "{$this->firstName} {$this->lastName}");
|
||||
}
|
||||
|
||||
public function loggedIn(?bool $set = null): bool
|
||||
|
||||
@ -37,7 +37,8 @@ class Authenticate {
|
||||
return null;
|
||||
}
|
||||
|
||||
public function forgetMe() {
|
||||
public function forgetMe() : void
|
||||
{
|
||||
$this->cookie->delete("user.id");
|
||||
$this->session->destroy();
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user