diff options
Diffstat (limited to 'samples/OAuthConsumer/SampleWcf2.aspx.cs')
-rw-r--r-- | samples/OAuthConsumer/SampleWcf2.aspx.cs | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/samples/OAuthConsumer/SampleWcf2.aspx.cs b/samples/OAuthConsumer/SampleWcf2.aspx.cs index 7978f91..9ff8c25 100644 --- a/samples/OAuthConsumer/SampleWcf2.aspx.cs +++ b/samples/OAuthConsumer/SampleWcf2.aspx.cs @@ -16,12 +16,9 @@ public partial class SampleWcf2 : System.Web.UI.Page { /// <summary> - /// The details about the sample OAuth-enabled WCF service that this sample client calls into. + /// The OAuth 2.0 client object to use to obtain authorization and authorize outgoing HTTP requests. /// </summary> - private static AuthorizationServerDescription AuthServerDescription = new AuthorizationServerDescription { - TokenEndpoint = new Uri("http://localhost:65169/OAuth.ashx"), - AuthorizationEndpoint = new Uri("http://localhost:65169/Members/Authorize.aspx"), - }; + private static readonly WebServerClient Client; /// <summary> /// Gets or sets the authorization details for the logged in user. @@ -37,17 +34,20 @@ } /// <summary> - /// The OAuth 2.0 client object to use to obtain authorization and authorize outgoing HTTP requests. - /// </summary> - private static readonly WebServerClient Client; - - /// <summary> - /// Initializes the <see cref="SampleWcf2"/> class. + /// Initializes static members of the <see cref="SampleWcf2"/> class. /// </summary> static SampleWcf2() { Client = new WebServerClient(AuthServerDescription, "sampleconsumer", "samplesecret"); } + /// <summary> + /// The details about the sample OAuth-enabled WCF service that this sample client calls into. + /// </summary> + private static AuthorizationServerDescription AuthServerDescription = new AuthorizationServerDescription { + TokenEndpoint = new Uri("http://localhost:65169/OAuth.ashx"), + AuthorizationEndpoint = new Uri("http://localhost:65169/Members/Authorize.aspx"), + }; + protected void Page_Load(object sender, EventArgs e) { if (!IsPostBack) { // Check to see if we're receiving a end user authorization response. |