summaryrefslogtreecommitdiffstats
path: root/src/DotNetOpenAuth.OAuth2.Client/OAuth2/WebServerClient.cs
diff options
context:
space:
mode:
authorAndrew Arnott <andrewarnott@gmail.com>2012-02-04 21:44:19 -0800
committerAndrew Arnott <andrewarnott@gmail.com>2012-02-04 21:44:19 -0800
commit759873533f4c3b117ab7aa7fe65191878c722a60 (patch)
tree863a93c055ae0c07f6167f10242b27caf9c1ef1c /src/DotNetOpenAuth.OAuth2.Client/OAuth2/WebServerClient.cs
parent4a7c65e52e69e38c8e8d633fbd39516a8b648053 (diff)
parentf48eb4274316121a7f640a41b2a5eb50b2f56874 (diff)
downloadDotNetOpenAuth-759873533f4c3b117ab7aa7fe65191878c722a60.zip
DotNetOpenAuth-759873533f4c3b117ab7aa7fe65191878c722a60.tar.gz
DotNetOpenAuth-759873533f4c3b117ab7aa7fe65191878c722a60.tar.bz2
Merge remote-tracking branch 'rafek/master'
Diffstat (limited to 'src/DotNetOpenAuth.OAuth2.Client/OAuth2/WebServerClient.cs')
-rw-r--r--src/DotNetOpenAuth.OAuth2.Client/OAuth2/WebServerClient.cs8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/DotNetOpenAuth.OAuth2.Client/OAuth2/WebServerClient.cs b/src/DotNetOpenAuth.OAuth2.Client/OAuth2/WebServerClient.cs
index 4f793a5..a4f6b21 100644
--- a/src/DotNetOpenAuth.OAuth2.Client/OAuth2/WebServerClient.cs
+++ b/src/DotNetOpenAuth.OAuth2.Client/OAuth2/WebServerClient.cs
@@ -53,9 +53,13 @@ namespace DotNetOpenAuth.OAuth2 {
/// </summary>
/// <param name="scopes">The scope of authorized access requested.</param>
/// <param name="state">The state of the client that should be sent back with the authorization response.</param>
+ /// <param name="returnTo">The URL the authorization server should redirect the browser (typically on this site) to when the authorization is completed. If null, the current request's URL will be used.</param>
/// <returns>The authorization request.</returns>
- public OutgoingWebResponse PrepareRequestUserAuthorization(IEnumerable<string> scopes = null, string state = null) {
- var authorizationState = new AuthorizationState(scopes);
+ public OutgoingWebResponse PrepareRequestUserAuthorization(IEnumerable<string> scopes = null, string state = null, Uri returnTo = null)
+ {
+ var authorizationState = new AuthorizationState(scopes) {
+ Callback = returnTo,
+ };
return this.PrepareRequestUserAuthorization(authorizationState, state);
}