Skip to content

Commit

Permalink
Fixed the reseting of the recovery codes when 2FA is disabled.
Browse files Browse the repository at this point in the history
  • Loading branch information
ruslanbaidan committed Aug 30, 2024
1 parent 93a247c commit e9818bc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Controller/ApiUserTwoFAController.php
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ public function delete($id)
{
$this->connectedUser->setTwoFactorAuthEnabled(false);
$this->connectedUser->setSecretKey('');
$this->connectedUser->setRecoveryCodes(null);
$this->connectedUser->setRecoveryCodes([]);
$this->userTable->save($this->connectedUser);

$this->getResponse()->setStatusCode(204);
Expand Down

0 comments on commit e9818bc

Please sign in to comment.