From 42ea0de9fb3ad310f6b47958269beb4c9bca6c07 Mon Sep 17 00:00:00 2001 From: Andrew Millington Date: Mon, 6 Nov 2017 21:19:38 +0000 Subject: [PATCH] Add default scope to the AbstractAuthorizeGrant --- src/Grant/AbstractAuthorizeGrant.php | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/Grant/AbstractAuthorizeGrant.php b/src/Grant/AbstractAuthorizeGrant.php index 7f05100c..6a8d7c07 100644 --- a/src/Grant/AbstractAuthorizeGrant.php +++ b/src/Grant/AbstractAuthorizeGrant.php @@ -13,6 +13,11 @@ namespace League\OAuth2\Server\Grant; abstract class AbstractAuthorizeGrant extends AbstractGrant { + /** + * @var string + */ + protected $defaultScope = ''; + /** * @param string $uri * @param array $params @@ -26,4 +31,12 @@ abstract class AbstractAuthorizeGrant extends AbstractGrant return $uri . http_build_query($params); } + + /** + * @param string $scope + */ + public function setDefaultScope($scope) + { + $this->defaultScope = $scope; + } }