Use the Odan session start middleware

This commit is contained in:
Dave Smith-Hayes 2024-12-09 14:29:03 +00:00
parent 5cd30f6f10
commit b69b29e54a

View File

@ -3,7 +3,7 @@
namespace Slovocast; namespace Slovocast;
use League\Config\Configuration; use League\Config\Configuration;
use Odan\Session\FlashInterface; use Odan\Session\Middleware\SessionStartMiddleware;
use Odan\Session\SessionInterface; use Odan\Session\SessionInterface;
use Psr\Container\ContainerExceptionInterface; use Psr\Container\ContainerExceptionInterface;
use Psr\Container\ContainerInterface; use Psr\Container\ContainerInterface;
@ -11,7 +11,6 @@ use Psr\Container\NotFoundExceptionInterface;
use Slim\App; use Slim\App;
use Slim\Views\Twig; use Slim\Views\Twig;
use Slim\Views\TwigMiddleware; use Slim\Views\TwigMiddleware;
use Slovocast\Middleware\SessionMiddleware;
use Twig\Error\LoaderError; use Twig\Error\LoaderError;
class Middlewares class Middlewares
@ -34,7 +33,7 @@ class Middlewares
/** /**
* Global session start * Global session start
*/ */
$app->add(SessionMiddleware::class); $app->add(SessionStartMiddleware::class);
// Twig // Twig
$templateCache = false; $templateCache = false;