Skip to content

Instantly share code, notes, and snippets.

@beyond-code-github
Created November 8, 2013 11:07
Show Gist options
  • Select an option

  • Save beyond-code-github/7369521 to your computer and use it in GitHub Desktop.

Select an option

Save beyond-code-github/7369521 to your computer and use it in GitHub Desktop.
CacheControlHeaderProvider = (request, cfg) =>
{
var matcher = new Regex("/Api/Notifications");
if (matcher.IsMatch(request.RequestUri.ToString()))
{
return null;
}
return new CacheControlHeaderValue
{
Private = true,
MustRevalidate = true,
NoTransform = true,
MaxAge = TimeSpan.Zero
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment