summaryrefslogtreecommitdiffstats
path: root/samples/OAuthAuthorizationServer/Controllers
diff options
context:
space:
mode:
authorAndrew Arnott <andrewarnott@gmail.com>2012-03-14 21:44:28 -0700
committerAndrew Arnott <andrewarnott@gmail.com>2012-03-14 21:44:28 -0700
commit85b43c815aa4fb069225ba31f9e763cd15bb6bc9 (patch)
treecc66acb6277379098377985e4e61698f6128e454 /samples/OAuthAuthorizationServer/Controllers
parentf4f32954757f128a3c4107df55c674be6314a8d3 (diff)
downloadDotNetOpenAuth-85b43c815aa4fb069225ba31f9e763cd15bb6bc9.zip
DotNetOpenAuth-85b43c815aa4fb069225ba31f9e763cd15bb6bc9.tar.gz
DotNetOpenAuth-85b43c815aa4fb069225ba31f9e763cd15bb6bc9.tar.bz2
Access token endpoint now can respond with appropriate errors.
Diffstat (limited to 'samples/OAuthAuthorizationServer/Controllers')
-rw-r--r--samples/OAuthAuthorizationServer/Controllers/OAuthController.cs7
1 files changed, 1 insertions, 6 deletions
diff --git a/samples/OAuthAuthorizationServer/Controllers/OAuthController.cs b/samples/OAuthAuthorizationServer/Controllers/OAuthController.cs
index 2a52e4f..4c3e4d4 100644
--- a/samples/OAuthAuthorizationServer/Controllers/OAuthController.cs
+++ b/samples/OAuthAuthorizationServer/Controllers/OAuthController.cs
@@ -21,12 +21,7 @@
/// </summary>
/// <returns>The response to the Client.</returns>
public ActionResult Token() {
- IDirectResponseProtocolMessage response;
- if (this.authorizationServer.TryPrepareAccessTokenResponse(out response)) {
- return this.authorizationServer.Channel.PrepareResponse(response).AsActionResult();
- } else {
- throw new HttpException((int)HttpStatusCode.BadRequest, "Missing OAuth 2.0 request message.");
- }
+ return this.authorizationServer.HandleTokenRequest(this.Request).AsActionResult();
}
/// <summary>