Added scopes to 2.0 apis

This commit is contained in:
Pablo Fernandez committed 2011-04-25 13:23:37 -03:00
1 parent 109c93b4e4
commit 2112d3d8a9
1 file changed
+1
@@ -32,6 +32,7 @@ public class OAuth20ServiceImpl implements OAuthService
request.addQuerystringParameter(OAuthConstants.CLIENT_SECRET, config.getApiSecret());
request.addQuerystringParameter(OAuthConstants.CODE, verifier.getValue());
request.addQuerystringParameter(OAuthConstants.REDIRECT_URI, config.getCallback());
if(config.hasScope()) request.addQuerystringParameter(OAuthConstants.SCOPE, config.getScope());
Response response = request.send();
return api.getAccessTokenExtractor().extract(response.getBody());
}