Projet

Général

Profil

Actions

Anomalie #1175

fermé

Redirection when not logged in fail

Ajouté par Johan Cwiklinski il y a presque 6 ans. Mis à jour il y a presque 6 ans.

Statut:
Fermé
Priorité:
Normal
Assigné à:
Catégorie:
Core
Version cible:
Début:
01/05/2018
Echéance:
% réalisé:

100%

Temps estimé:
Version utilisée:

Description

When you try to open a restricted URL and you're not loggd in; Galette should redirect you to the login page, but currently it displays a blank page.

It looks like the "403" code passed is the cause:

diff --git a/galette/includes/main.inc.php b/galette/includes/main.inc.php
index de440045..e165de47 100644
--- a/galette/includes/main.inc.php
+++ b/galette/includes/main.inc.php
@@ -155,7 +155,6 @@ $authenticate = function ($request, $response, $next) use ($container) {
         );
         $this->flash->addMessage('error_detected', _T("Login required"));
         return $response
-            ->withStatus(403)
             ->withHeader('Location', $this->router->pathFor('slash'));
     } else {
         //check for ACLs

Actions

Formats disponibles : Atom PDF