Update Page\Auth
This commit is contained in:
parent
dff5481070
commit
020b0f0ca0
1 changed files with 3 additions and 9 deletions
|
@ -362,7 +362,7 @@ class Auth extends Page
|
|||
{
|
||||
if (
|
||||
! \hash_equals($args['hash'], $this->c->Secury->hash($args['id'] . $args['key']))
|
||||
|| ! ($user = $this->c->users->load((int) $args['id'])) instanceof User
|
||||
|| ! ($user = $this->c->users->load($args['id'])) instanceof User
|
||||
|| ! \hash_equals($user->activate_string, $args['key'])
|
||||
) {
|
||||
$this->c->Log->warning('Passphrase reset: confirmation, fail', [
|
||||
|
@ -453,15 +453,9 @@ class Auth extends Page
|
|||
protected function formChange(array $args): array
|
||||
{
|
||||
return [
|
||||
'action' => $this->c->Router->link(
|
||||
'ChangePassword',
|
||||
$args
|
||||
),
|
||||
'action' => $this->c->Router->link('ChangePassword', $args),
|
||||
'hidden' => [
|
||||
'token' => $this->c->Csrf->create(
|
||||
'ChangePassword',
|
||||
$args
|
||||
),
|
||||
'token' => $this->c->Csrf->create('ChangePassword', $args),
|
||||
],
|
||||
'sets' => [
|
||||
'forget' => [
|
||||
|
|
Loading…
Add table
Reference in a new issue