diff --git a/typo3/sysext/felogin/Classes/Service/RecoveryService.php b/typo3/sysext/felogin/Classes/Service/RecoveryService.php index a460d3d899054891a51fbead07678794805b3ff1..2b19652e2c38b2b03ed4b79e13aa3569e87ce4be 100644 --- a/typo3/sysext/felogin/Classes/Service/RecoveryService.php +++ b/typo3/sysext/felogin/Classes/Service/RecoveryService.php @@ -138,7 +138,9 @@ class RecoveryService implements RecoveryServiceInterface */ protected function prepareMail(Address $receiver, string $hash): Email { - $url = $this->uriBuilder->setCreateAbsoluteUri(true) + $url = $this->uriBuilder + ->reset() + ->setCreateAbsoluteUri(true) ->uriFor( 'showChangePassword', ['hash' => $hash], diff --git a/typo3/sysext/felogin/Tests/Unit/Service/RecoveryServiceTest.php b/typo3/sysext/felogin/Tests/Unit/Service/RecoveryServiceTest.php index 9e9d15ec1248577d1b54c53ed64c491f8fdc572d..3e28641ba73f1f1d7d87f12cd883aad8f07da1a1 100644 --- a/typo3/sysext/felogin/Tests/Unit/Service/RecoveryServiceTest.php +++ b/typo3/sysext/felogin/Tests/Unit/Service/RecoveryServiceTest.php @@ -94,6 +94,7 @@ class RecoveryServiceTest extends UnitTestCase $languageService->sL(Argument::containingString('password_recovery_mail_header'))->willReturn('translation'); $uriBuilder = $this->prophesize(UriBuilder::class); + $uriBuilder->reset()->willReturn($uriBuilder->reveal()); $uriBuilder->setCreateAbsoluteUri(true)->willReturn($uriBuilder->reveal()); $uriBuilder->uriFor( 'showChangePassword',