More CS fixer changes

This commit is contained in:
Alex Bilbie
2014-05-03 10:53:57 +01:00
parent 97e7a00bca
commit ed7f5370ca
14 changed files with 50 additions and 71 deletions

View File

@ -11,16 +11,11 @@
namespace League\OAuth2\Server\Grant; namespace League\OAuth2\Server\Grant;
use League\OAuth2\Server\AuthorizationServer;
use League\OAuth2\Server\Entity\AccessTokenEntity; use League\OAuth2\Server\Entity\AccessTokenEntity;
use League\OAuth2\Server\Entity\ClientEntity; use League\OAuth2\Server\Entity\ClientEntity;
use League\OAuth2\Server\Entity\SessionEntity; use League\OAuth2\Server\Entity\SessionEntity;
use League\OAuth2\Server\Entity\ScopeEntity;
use League\OAuth2\Server\Exception; use League\OAuth2\Server\Exception;
use League\OAuth2\Server\Util\SecureKey; use League\OAuth2\Server\Util\SecureKey;
use League\OAuth2\Server\Storage\SessionInterface;
use League\OAuth2\Server\Storage\ClientInterface;
use League\OAuth2\Server\Storage\ScopeInterface;
/** /**
* Client credentials grant class * Client credentials grant class

View File

@ -11,14 +11,6 @@
namespace League\OAuth2\Server\Grant; namespace League\OAuth2\Server\Grant;
use League\OAuth2\Server\Request;
use League\OAuth2\Server\Authorization;
use League\OAuth2\Server\Exception;
use League\OAuth2\Server\Util\SecureKey;
use League\OAuth2\Server\Storage\SessionInterface;
use League\OAuth2\Server\Storage\ClientInterface;
use League\OAuth2\Server\Storage\ScopeInterface;
/** /**
* Grant type interface * Grant type interface
*/ */

View File

@ -11,17 +11,12 @@
namespace League\OAuth2\Server\Grant; namespace League\OAuth2\Server\Grant;
use League\OAuth2\Server\AuthorizationServer;
use League\OAuth2\Server\Entity\ClientEntity; use League\OAuth2\Server\Entity\ClientEntity;
use League\OAuth2\Server\Entity\AccessTokenEntity; use League\OAuth2\Server\Entity\AccessTokenEntity;
use League\OAuth2\Server\Entity\RefreshTokenEntity; use League\OAuth2\Server\Entity\RefreshTokenEntity;
use League\OAuth2\Server\Entity\SessionEntity; use League\OAuth2\Server\Entity\SessionEntity;
use League\OAuth2\Server\Entity\ScopeEntity;
use League\OAuth2\Server\Exception; use League\OAuth2\Server\Exception;
use League\OAuth2\Server\Util\SecureKey; use League\OAuth2\Server\Util\SecureKey;
use League\OAuth2\Server\Storage\SessionInterface;
use League\OAuth2\Server\Storage\ClientInterface;
use League\OAuth2\Server\Storage\ScopeInterface;
/** /**
* Password grant class * Password grant class

View File

@ -12,15 +12,10 @@
namespace League\OAuth2\Server\Grant; namespace League\OAuth2\Server\Grant;
use League\OAuth2\Server\Request; use League\OAuth2\Server\Request;
use League\OAuth2\Server\AuthorizationServer;
use League\OAuth2\Server\Exception; use League\OAuth2\Server\Exception;
use League\OAuth2\Server\Util\SecureKey; use League\OAuth2\Server\Util\SecureKey;
use League\OAuth2\Server\Storage\SessionInterface;
use League\OAuth2\Server\Storage\ClientInterface;
use League\OAuth2\Server\Storage\ScopeInterface;
use League\OAuth2\Server\Entity\RefreshTokenEntity; use League\OAuth2\Server\Entity\RefreshTokenEntity;
use League\OAuth2\Server\Entity\AccessTokenEntity; use League\OAuth2\Server\Entity\AccessTokenEntity;
use League\OAuth2\Server\Entity\SessionEntity;
use League\OAuth2\Server\Entity\ClientEntity; use League\OAuth2\Server\Entity\ClientEntity;
/** /**

View File

@ -11,10 +11,8 @@
namespace League\OAuth2\Server; namespace League\OAuth2\Server;
use League\OAuth2\Server\Storage\StorageWrapper;
use League\OAuth2\Server\Storage\ClientInterface; use League\OAuth2\Server\Storage\ClientInterface;
use League\OAuth2\Server\Storage\AccessTokenInterface; use League\OAuth2\Server\Storage\AccessTokenInterface;
use League\OAuth2\Server\Storage\AuthCodeInterface;
use League\OAuth2\Server\Storage\SessionInterface; use League\OAuth2\Server\Storage\SessionInterface;
use League\OAuth2\Server\Storage\ScopeInterface; use League\OAuth2\Server\Storage\ScopeInterface;
use League\OAuth2\Server\Entity\AccessTokenEntity; use League\OAuth2\Server\Entity\AccessTokenEntity;
@ -76,6 +74,7 @@ class ResourceServer extends AbstractServer
{ {
$storage->setServer($this); $storage->setServer($this);
$this->storages[$type] = $storage; $this->storages[$type] = $storage;
return $this; return $this;
} }
@ -96,6 +95,7 @@ class ResourceServer extends AbstractServer
public function setTokenKey($key) public function setTokenKey($key)
{ {
$this->tokenKey = $key; $this->tokenKey = $key;
return $this; return $this;
} }
@ -162,6 +162,7 @@ class ResourceServer extends AbstractServer
} }
} }
} }
return true; return true;
} }
@ -176,6 +177,7 @@ class ResourceServer extends AbstractServer
// Set the access token // Set the access token
$this->accessToken = $this->storages['access_token']->get($accessTokenString); $this->accessToken = $this->storages['access_token']->get($accessTokenString);
return ($this->accessToken instanceof AccessTokenEntity); return ($this->accessToken instanceof AccessTokenEntity);
} }

View File

@ -14,7 +14,6 @@ namespace League\OAuth2\Server\Storage;
use League\OAuth2\Server\Entity\AccessTokenEntity; use League\OAuth2\Server\Entity\AccessTokenEntity;
use League\OAuth2\Server\Entity\AbstractTokenEntity; use League\OAuth2\Server\Entity\AbstractTokenEntity;
use League\OAuth2\Server\Entity\RefreshTokenEntity; use League\OAuth2\Server\Entity\RefreshTokenEntity;
use League\OAuth2\Server\Entity\AuthCodeEntity;
use League\OAuth2\Server\Entity\ScopeEntity; use League\OAuth2\Server\Entity\ScopeEntity;
/** /**

View File

@ -31,6 +31,7 @@ class Adapter
public function setServer(AbstractServer $server) public function setServer(AbstractServer $server)
{ {
$this->server = $server; $this->server = $server;
return $this; return $this;
} }

View File

@ -11,7 +11,6 @@
namespace League\OAuth2\Server\Util\KeyAlgorithm; namespace League\OAuth2\Server\Util\KeyAlgorithm;
class DefaultAlgorithm implements KeyAlgorithmInterface class DefaultAlgorithm implements KeyAlgorithmInterface
{ {
/** /**

View File

@ -26,6 +26,7 @@ class RedirectUri
public static function make($uri, $params = array(), $queryDelimeter = '?') public static function make($uri, $params = array(), $queryDelimeter = '?')
{ {
$uri .= (strstr($uri, $queryDelimeter) === false) ? $queryDelimeter : '&'; $uri .= (strstr($uri, $queryDelimeter) === false) ? $queryDelimeter : '&';
return $uri.http_build_query($params); return $uri.http_build_query($params);
} }
} }