Permalink
Browse files

Avoid making case sensitive comparisons when adjusting for virtual di…

…rectories
  • Loading branch information...
1 parent 40c95cc commit 43915a7039acff022e9117ee12331af0a6ae7652 @ayende ayende committed Jul 8, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 Raven.Http/Extensions/HttpExtensions.cs
@@ -266,14 +266,14 @@ public static void AdjustUrl(this IHttpContext self, string token)
public static void RemoveFromRequestUrl(this IHttpRequest self, string token)
{
- if (self.Url.LocalPath.StartsWith(token))
+ if (self.Url.LocalPath.StartsWith(token, StringComparison.InvariantCultureIgnoreCase))
{
self.Url = new UriBuilder(self.Url)
{
Path = self.Url.LocalPath.Substring(token.Length)
}.Uri;
}
- if (self.RawUrl.StartsWith(token))
+ if (self.RawUrl.StartsWith(token, StringComparison.InvariantCultureIgnoreCase))
{
self.RawUrl = self.RawUrl.Substring(token.Length);
}

0 comments on commit 43915a7

Please sign in to comment.