Skip to content
This repository has been archived by the owner on Sep 9, 2022. It is now read-only.

Commit

Permalink
Automatic merge from TeamCity build #13, branch release/2.0.0. Releas…
Browse files Browse the repository at this point in the history
…e 2.0.0 is ready.
  • Loading branch information
ciadmin committed Feb 8, 2016
2 parents e93604a + 9581ac0 commit 83a4627
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ var clientCompressionHandler = new ClientCompressionHandler(4096, new GZipCompre
The above code will skip compression for any request/response that is smaller than `4096 bytes` / `4 kB`.

#### Disable compression for endpoint
It is possible to disable compression for a specific endpoint. Just add the `[EnableCompression(false)]` attribute to your endpoint method. (Or the whole controller if you want to disable for all endpoints in it)
It is possible to disable compression for a specific endpoint. Just add the `[Compression(Enabled = false)]` attribute to your endpoint method. (Or the whole controller if you want to disable for all endpoints in it)

#### OWIN Authentication
When using the OWIN Authentication pipeline, you might encounter errors saying that `Server cannot append header after http headers have been sent`. This is a [bug with OWIN](http://katanaproject.codeplex.com/discussions/540202), but as of this moment it has not been fixed.
Expand Down
2 changes: 1 addition & 1 deletion src/Server/Attributes/CompressionAttribute.cs
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public CompressionAttribute()
/// <returns>A Task.</returns>
public override Task OnActionExecutingAsync(HttpActionContext actionContext, CancellationToken cancellationToken)
{
actionContext.Request.Properties.Add("compression:Enable", this.Enabled);
actionContext.Request.Properties["compression:Enable"] = this.Enabled;

return base.OnActionExecutingAsync(actionContext, cancellationToken);
}
Expand Down

0 comments on commit 83a4627

Please sign in to comment.