mirror of
https://github.com/elyby/oauth2-server.git
synced 2025-01-11 22:32:07 +05:30
Added getQueryStringParameter method
This commit is contained in:
parent
d96f57d27f
commit
bfcf7af4d8
@ -239,6 +239,20 @@ abstract class AbstractGrant implements GrantTypeInterface
|
||||
return (isset($request->getParsedBody()[$parameter])) ? $request->getParsedBody()[$parameter] : $default;
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve query string parameter.
|
||||
*
|
||||
* @param string $parameter
|
||||
* @param \Psr\Http\Message\ServerRequestInterface $request
|
||||
* @param mixed $default
|
||||
*
|
||||
* @return null|string
|
||||
*/
|
||||
protected function getQueryStringParameter($parameter, ServerRequestInterface $request, $default = null)
|
||||
{
|
||||
return (isset($request->getQueryParams()[$parameter])) ? $request->getQueryParams()[$parameter] : $default;
|
||||
}
|
||||
|
||||
/**
|
||||
* Retrieve server parameter.
|
||||
*
|
||||
|
Loading…
x
Reference in New Issue
Block a user