From 73d4cacaf17cc18b8e84557a2aa4e8dc4029eccb Mon Sep 17 00:00:00 2001 From: Paul Isaris Date: Fri, 13 Dec 2024 11:08:19 +0200 Subject: [PATCH] Bugfix --- app/Http/Controllers/HomeController.php | 4 ++++ resources/views/code-of-conduct/en.blade.php | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/app/Http/Controllers/HomeController.php b/app/Http/Controllers/HomeController.php index 844c87f7a..a923f1f97 100644 --- a/app/Http/Controllers/HomeController.php +++ b/app/Http/Controllers/HomeController.php @@ -61,8 +61,12 @@ private function getRedirectBackUrl(): string { if (!Str::contains($referrer, '?open')) { $goBackUrl .= '?open=1'; } //so user can go back and open the questionnaire + } else { + $goBackUrl = $referrer; } } + } else { + $goBackUrl = route('home'); } return $goBackUrl; diff --git a/resources/views/code-of-conduct/en.blade.php b/resources/views/code-of-conduct/en.blade.php index 45c7ce4d1..d32341d09 100644 --- a/resources/views/code-of-conduct/en.blade.php +++ b/resources/views/code-of-conduct/en.blade.php @@ -111,7 +111,7 @@ @if ($goBackUrl)
Back to the questionnaire + class="fas fa-long-arrow-alt-left"> Go Back
@endif