mirror of
https://github.com/elyby/oauth2-server.git
synced 2024-11-01 08:23:03 +05:30
Merge pull request #918 from Sephster/fix-914
Fix empty issue in PHP 5.4
This commit is contained in:
commit
138524984a
@ -138,7 +138,9 @@ class ResourceServer extends AbstractServer
|
||||
*/
|
||||
public function determineAccessToken($headerOnly = false)
|
||||
{
|
||||
if (!empty($this->getRequest()->headers->get('Authorization'))) {
|
||||
$authHeader = $this->getRequest()->headers->get('Authorization');
|
||||
|
||||
if (!empty($authHeader)) {
|
||||
$accessToken = $this->getTokenType()->determineAccessTokenInHeader($this->getRequest());
|
||||
} elseif ($headerOnly === false && (! $this->getTokenType() instanceof MAC)) {
|
||||
$accessToken = ($this->getRequest()->server->get('REQUEST_METHOD') === 'GET')
|
||||
|
Loading…
Reference in New Issue
Block a user