Skip to content

Commit

Permalink
One login page behind feature flag
Browse files Browse the repository at this point in the history
  • Loading branch information
MishNajam committed Oct 16, 2023
1 parent 612f840 commit 0a1f718
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion service-front/app/config/routes.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
declare(strict_types=1);

use Common\Middleware\Routing\ConditionalRoutingMiddleware;
use Actor\Handler\AuthoriseOneLoginHandler;
use Mezzio\Application;
use Mezzio\MiddlewareFactory;
use Psr\Container\ContainerInterface;
Expand Down Expand Up @@ -64,6 +65,7 @@
$actorRoutes = function (Application $app, MiddlewareFactory $factory, ContainerInterface $container): void {
$USE_OLDER_LPA_JOURNEY = 'use_older_lpa_journey';
$DELETE_LPA_FEATURE = 'delete_lpa_feature';
$ALLOW_GOV_ONE_LOGIN = getenv('ALLOW_GOV_ONE_LOGIN');

$defaultNotFoundPage = Actor\Handler\LpaDashboardHandler::class;

Expand All @@ -89,7 +91,9 @@

// User auth
$app->route('/login', Actor\Handler\LoginPageHandler::class, ['GET', 'POST'], 'login');
$app->route('/one-login', Actor\Handler\AuthoriseOneLoginHandler::class, ['GET', 'POST'], 'one-login');
if ($ALLOW_GOV_ONE_LOGIN == 'true') {
$app->route('/one-login', Actor\Handler\AuthoriseOneLoginHandler::class, ['GET', 'POST'], 'one-login');
}
$app->get('/session-expired', Actor\Handler\ActorSessionExpiredHandler::class, 'session-expired');
$app->get('/session-check', Actor\Handler\ActorSessionCheckHandler::class, 'session-check');
$app->get('/session-refresh', Common\Handler\SessionRefreshHandler::class, 'session-refresh');
Expand Down

0 comments on commit 0a1f718

Please sign in to comment.