Skip to content

Commit 1bf0529

Browse files
committed
Issue #478: Require symfony/var-exporter to keep LazyGhost support
Signed-off-by: alexmerlin <[email protected]>
1 parent 64f7124 commit 1bf0529

File tree

2 files changed

+15
-2
lines changed

2 files changed

+15
-2
lines changed

src/App/src/ConfigProvider.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ public function getDependencies(): array
6363
'doctrine.entity_manager.orm_default' => EntityManagerFactory::class,
6464
'dot-mail.options.default' => MailOptionsAbstractFactory::class,
6565
'dot-mail.service.default' => MailServiceAbstractFactory::class,
66-
AuthenticationMiddleware::class => AuthenticationMiddlewareFactory::class,
66+
AuthenticationMiddleware::class => AnnotatedServiceFactory::class,
6767
AuthorizationMiddleware::class => AnnotatedServiceFactory::class,
6868
ContentNegotiationMiddleware::class => AnnotatedServiceFactory::class,
6969
Environment::class => TwigEnvironmentFactory::class,

src/App/src/Middleware/AuthenticationMiddleware.php

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,26 @@
66

77
use Api\App\UserIdentity;
88
use Api\User\Entity\UserRole;
9+
use Dot\AnnotatedServices\Annotation\Inject;
10+
use Mezzio\Authentication\AuthenticationInterface;
911
use Mezzio\Authentication\UserInterface;
1012
use Psr\Http\Message\ResponseInterface;
1113
use Psr\Http\Message\ServerRequestInterface;
14+
use Psr\Http\Server\MiddlewareInterface;
1215
use Psr\Http\Server\RequestHandlerInterface;
1316

14-
class AuthenticationMiddleware extends \Mezzio\Authentication\AuthenticationMiddleware
17+
class AuthenticationMiddleware implements MiddlewareInterface
1518
{
19+
/**
20+
* @Inject({
21+
* AuthenticationInterface::class,
22+
* })
23+
*/
24+
public function __construct(
25+
protected AuthenticationInterface $auth,
26+
) {
27+
}
28+
1629
public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface
1730
{
1831
$user = $this->auth->authenticate($request);

0 commit comments

Comments
 (0)