Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Using ApiController as discriminator for HttpHeaderValueProviderFactory

  • Loading branch information...
commit 72753c9fa2b44e6826b9ede0145500c81d301a19 1 parent 3d9c3e7
@pranavkm pranavkm authored
Showing with 1 addition and 1 deletion.
  1. +1 −1  Website/Infrastructure/HttpHeaderValueProviderFactory.cs
View
2  Website/Infrastructure/HttpHeaderValueProviderFactory.cs
@@ -10,7 +10,7 @@ public override IValueProvider GetValueProvider(ControllerContext controllerCont
var request = controllerContext.RequestContext.HttpContext.Request;
// Use this value provider only if a route is located under "API"
- if (request.Path.TrimStart('/').StartsWith("api", StringComparison.OrdinalIgnoreCase))
+ if (controllerContext.Controller is ApiController)
return new HttpHeaderValueProvider(request, "ApiKey");
return null;
}
Please sign in to comment.
Something went wrong with that request. Please try again.