Permalink
Browse files

MDL-33507 - oauth2lib: switch 'code' to oauth2code

To avoid param collisions in future.
  • Loading branch information...
danpoltawski committed Jun 4, 2012
1 parent 5df1b73 commit 7b61ac39d2674f3ce9f7a5dadc4ea85d7ded8f50
Showing with 2 additions and 2 deletions.
  1. +1 −1 admin/oauth2callback.php
  2. +1 −1 lib/oauthlib.php
View
@@ -39,7 +39,7 @@
$params = $redirecturl->params();
if (isset($params['sesskey']) and confirm_sesskey($params['sesskey'])) {
$redirecturl->param('code', $code);
$redirecturl->param('oauth2code', $code);
redirect($redirecturl);
} else {
print_error('invalidsesskey');
View
@@ -425,7 +425,7 @@ public function is_logged_in() {
// If we've been passed then authorization code generated by the
// authorization server try and upgrade the token to an access token.
$code = optional_param('code', null, PARAM_RAW);
$code = optional_param('oauth2code', null, PARAM_RAW);
if ($code && $this->upgrade_token($code)) {
return true;
}

0 comments on commit 7b61ac3

Please sign in to comment.