From 3c19fb40830e1541d9eefad99a58a1cfc82a8760 Mon Sep 17 00:00:00 2001 From: Westin Shafer Date: Thu, 1 Mar 2018 16:31:44 -0700 Subject: [PATCH] Adds the AuthenticationInterface to the config provider --- src/ConfigProvider.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/ConfigProvider.php b/src/ConfigProvider.php index c7f3533..d57246b 100644 --- a/src/ConfigProvider.php +++ b/src/ConfigProvider.php @@ -18,6 +18,7 @@ use League\OAuth2\Server\Repositories\ScopeRepositoryInterface; use League\OAuth2\Server\Repositories\UserRepositoryInterface; use League\OAuth2\Server\ResourceServer; +use Zend\Expressive\Authentication\AuthenticationInterface; use Zend\Expressive\Authentication\OAuth2\Repository\Pdo; class ConfigProvider @@ -47,7 +48,8 @@ public function getDependencies() : array ClientRepositoryInterface::class => Pdo\ClientRepository::class, RefreshTokenRepositoryInterface::class => Pdo\RefreshTokenRepository::class, ScopeRepositoryInterface::class => Pdo\ScopeRepository::class, - UserRepositoryInterface::class => Pdo\UserRepository::class + UserRepositoryInterface::class => Pdo\UserRepository::class, + AuthenticationInterface::class => OAuth2Adapter::class ], 'factories' => [ OAuth2Middleware::class => OAuth2MiddlewareFactory::class,