Skip to content
Snippets Groups Projects
Commit 395c0c22 authored by Hahn Axel (hahn)'s avatar Hahn Axel (hahn)
Browse files

fix redirect class

parent 2e250427
No related branches found
No related tags found
1 merge request!57512 php83 update
This commit is part of merge request !5. Comments created here will be created in the context of that merge request.
......@@ -278,7 +278,7 @@ class redirect
public function setRequest(string $sRequest): bool
{
$this->sRequest = $sRequest;
$this->aRedirect = false;
$this->aRedirect = [];
return true;
}
......@@ -294,7 +294,7 @@ class redirect
*/
public function getRedirect(): array
{
if (is_array($this->aRedirect)) {
if (is_array($this->aRedirect) && count($this->aRedirect)) {
return $this->aRedirect;
}
......@@ -341,7 +341,7 @@ class redirect
public function getRedirectTarget(): string
{
$aRedirect = $this->getRedirect();
return $aRedirect['target'] ?? '';
return isset($aRedirect['target']) ? $aRedirect['target'] : false;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment