From 2ba9a1d279ba13b01ab3ca7d59119da4c9813734 Mon Sep 17 00:00:00 2001 From: Alex Bilbie Date: Fri, 6 Jul 2012 19:31:36 +0100 Subject: [PATCH] Comment changes --- src/oauth2server/Server.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/oauth2server/Server.php b/src/oauth2server/Server.php index 15109983..58858db0 100644 --- a/src/oauth2server/Server.php +++ b/src/oauth2server/Server.php @@ -239,7 +239,8 @@ class Server { $authCode = $this->generateCode(); - // Update an existing session with the new code + // If an access token exists then update the existing session with the + // new authorisation code otherwise create a new session if ($access_token !== null) { $this->db->updateSession( @@ -251,7 +252,7 @@ class Server 'request' ); - } else { // Create a new oauth session + } else { // Delete any existing sessions just to be sure $this->db->deleteSession($clientId, $type, $typeId);