Skip to content

Commit

Permalink
[BUGFIX] Initialize strictly typed property setCookie with null
Browse files Browse the repository at this point in the history
Releases: master
Resolves: #93069
Relates: #93011
Change-Id: I80c970009694462d48ec65f96eb9b0f29cacf18c
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/67108
Tested-by: TYPO3com <noreply@typo3.com>
Tested-by: Andreas Fernandez <a.fernandez@scripting-base.de>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Andreas Fernandez <a.fernandez@scripting-base.de>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
  • Loading branch information
ervaude authored and lolli42 committed Dec 14, 2020
1 parent b2a2281 commit 0beac0b
Showing 1 changed file with 2 additions and 2 deletions.
Expand Up @@ -212,7 +212,7 @@ abstract class AbstractUserAuthentication implements LoggerAwareInterface
*
* @var Cookie|null
*/
protected ?Cookie $setCookie;
protected ?Cookie $setCookie = null;

/**
* Initialize some important variables
Expand Down Expand Up @@ -285,7 +285,7 @@ public function start()
*/
public function appendCookieToResponse(ResponseInterface $response): ResponseInterface
{
if (isset($this->setCookie)) {
if ($this->setCookie !== null) {
$response = $response->withAddedHeader('Set-Cookie', $this->setCookie->__toString());
}
return $response;
Expand Down

0 comments on commit 0beac0b

Please sign in to comment.