Skip to content
This repository has been archived by the owner on Mar 23, 2024. It is now read-only.

Commit

Permalink
🚿
Browse files Browse the repository at this point in the history
  • Loading branch information
codemasher committed Mar 22, 2024
1 parent e8384c6 commit d6a171e
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 5 deletions.
4 changes: 2 additions & 2 deletions examples/OAuthProviderFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -43,9 +43,9 @@ public function __construct(
protected UriFactoryInterface $uriFactory,
protected string $cfgDir = __DIR__.'/../config',
string $envFile = '.env',
string $logLevel = null,
string|null $logLevel = null,
){
ini_set('date.timezone', 'Europe/Amsterdam');
ini_set('date.timezone', 'UTC');

$this->dotEnv = (new DotEnv($this->cfgDir, $envFile, false))->load();
$this->logger = $this->initLogger($logLevel);
Expand Down
4 changes: 2 additions & 2 deletions examples/provider-example-common.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,16 @@
/**
* these vars are supposed to be set before this file is included to ease testing
*
* @var string $CFGDIR - the directory where configuration is stored (.env, cacert, tokens)
* @var string $ENVFILE - the name of the .env file in case it differs from the default
* @var string $ENVVAR - name prefix for the environment variable
* @var string $CFGDIR - the directory where configuration is stored (.env, cacert, tokens)
* @var string $LOGLEVEL - log level for the test logger, use 'none' to suppress logging
* @var array|null $PARAMS - additional params to pass to getAuthURL()
* @var array|null $SCOPES - a set of scopes for the current provider (OAuth2 only)
*/
$CFGDIR ??= __DIR__.'/../config';
$ENVFILE ??= '.env';
$ENVVAR ??= '';
$CFGDIR ??= __DIR__.'/../config';
$LOGLEVEL ??= 'info';
$PARAMS ??= null;
$SCOPES ??= null;
Expand Down
2 changes: 1 addition & 1 deletion src/Core/OAuthProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -315,7 +315,7 @@ protected function getRequestBody(StreamInterface|array|string $body, RequestInt

}

throw new ProviderException('invalid body/content-type'); // @codeCoverageIgnore
throw new ProviderException('invalid body/content-type');
}

/**
Expand Down
2 changes: 2 additions & 0 deletions src/OAuthOptionsTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ trait OAuthOptionsTrait{
/**
* Whether to start the session when session storage is used
*
* Note: this will only start a session if there is no active session present
*
* @see \chillerlan\OAuth\Storage\SessionStorage
*/
protected bool $sessionStart = true;
Expand Down

0 comments on commit d6a171e

Please sign in to comment.