From 591139f44d8ac150d95ea57e0395dfb4e75ab84a Mon Sep 17 00:00:00 2001 From: Alex Bilbie Date: Fri, 10 May 2013 16:57:12 -0700 Subject: [PATCH] Added associateAuthCodeScope to PDO --- src/League/OAuth2/Server/Storage/PDO/Session.php | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/League/OAuth2/Server/Storage/PDO/Session.php b/src/League/OAuth2/Server/Storage/PDO/Session.php index 87716522..d03446d6 100644 --- a/src/League/OAuth2/Server/Storage/PDO/Session.php +++ b/src/League/OAuth2/Server/Storage/PDO/Session.php @@ -161,6 +161,16 @@ class Session implements SessionInterface return ($result === false) ? false : (array) $result; } + public function associateAuthCodeScope($sessionId, $scopeId) + { + $db = \ezcDbInstance::get(); + + $stmt = $db->prepare('INSERT INTO `oauth_session_authcode_scopes` (`session_id`, `scope_id`) VALUES (:sessionId, :scopeId)'); + $stmt->bindValue(':sessionId', $sessionId); + $stmt->bindValue(':scopeId', $scopeId); + $stmt->execute(); + } + public function associateScope($accessTokenId, $scopeId) { $db = \ezcDbInstance::get();