Removed default wording as there are no overrides

This commit is contained in:
Alex Bilbie 2016-01-17 14:23:02 +00:00
parent 5a8659471c
commit 0486d93fa3

View File

@ -39,7 +39,7 @@ class Server implements EmitterAwareInterface
/** /**
* @var string * @var string
*/ */
protected $defaultPrivateKeyPath; protected $privateKeyPath;
/** /**
* @var ResponseTypeInterface * @var ResponseTypeInterface
@ -49,7 +49,7 @@ class Server implements EmitterAwareInterface
/** /**
* @var string * @var string
*/ */
private $defaultPublicKeyPath; private $publicKeyPath;
/** /**
* @var \League\OAuth2\Server\Repositories\ClientRepositoryInterface * @var \League\OAuth2\Server\Repositories\ClientRepositoryInterface
@ -72,24 +72,24 @@ class Server implements EmitterAwareInterface
* @param \League\OAuth2\Server\Repositories\ClientRepositoryInterface $clientRepository * @param \League\OAuth2\Server\Repositories\ClientRepositoryInterface $clientRepository
* @param \League\OAuth2\Server\Repositories\AccessTokenRepositoryInterface $accessTokenRepository * @param \League\OAuth2\Server\Repositories\AccessTokenRepositoryInterface $accessTokenRepository
* @param \League\OAuth2\Server\Repositories\ScopeRepositoryInterface $scopeRepository * @param \League\OAuth2\Server\Repositories\ScopeRepositoryInterface $scopeRepository
* @param string $defaultPrivateKeyPath * @param string $privateKeyPath
* @param string $defaultPublicKeyPath * @param string $publicKeyPath
* @param null|\League\OAuth2\Server\ResponseTypes\ResponseTypeInterface $responseType * @param null|\League\OAuth2\Server\ResponseTypes\ResponseTypeInterface $responseType
*/ */
public function __construct( public function __construct(
ClientRepositoryInterface $clientRepository, ClientRepositoryInterface $clientRepository,
AccessTokenRepositoryInterface $accessTokenRepository, AccessTokenRepositoryInterface $accessTokenRepository,
ScopeRepositoryInterface $scopeRepository, ScopeRepositoryInterface $scopeRepository,
$defaultPrivateKeyPath, $privateKeyPath,
$defaultPublicKeyPath, $publicKeyPath,
ResponseTypeInterface $responseType = null ResponseTypeInterface $responseType = null
) { ) {
$this->defaultPrivateKeyPath = $defaultPrivateKeyPath;
$this->defaultPublicKeyPath = $defaultPublicKeyPath;
$this->clientRepository = $clientRepository; $this->clientRepository = $clientRepository;
$this->accessTokenRepository = $accessTokenRepository; $this->accessTokenRepository = $accessTokenRepository;
$this->scopeRepository = $scopeRepository; $this->scopeRepository = $scopeRepository;
$this->defaultResponseType = $responseType; $this->defaultResponseType = $responseType;
$this->privateKeyPath = $privateKeyPath;
$this->publicKeyPath = $publicKeyPath;
} }
/** /**
@ -123,6 +123,8 @@ class Server implements EmitterAwareInterface
$grantType->setAccessTokenRepository($this->accessTokenRepository); $grantType->setAccessTokenRepository($this->accessTokenRepository);
$grantType->setClientRepository($this->clientRepository); $grantType->setClientRepository($this->clientRepository);
$grantType->setScopeRepository($this->scopeRepository); $grantType->setScopeRepository($this->scopeRepository);
$grantType->setPathToPrivateKey($this->privateKeyPath);
$grantType->setPathToPublicKey($this->publicKeyPath);
$grantType->setEmitter($this->getEmitter()); $grantType->setEmitter($this->getEmitter());
$this->enabledGrantTypes[$grantType->getIdentifier()] = $grantType; $this->enabledGrantTypes[$grantType->getIdentifier()] = $grantType;