Skip to content
Browse files

Replace fix for #722 (should be closed)

  • Loading branch information...
1 parent 77946ed commit dab5592e4187047a708094acbaa8f898585fe590 @thecodejunkie thecodejunkie committed
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/Nancy.Hosting.Aspnet/NancyHandler.cs
View
4 src/Nancy.Hosting.Aspnet/NancyHandler.cs
@@ -101,12 +101,12 @@ private static void SetNancyResponseToHttpResponse(HttpContextBase context, Resp
private static void SetHttpResponseHeaders(HttpContextBase context, Response response)
{
- foreach (var header in response.Headers)
+ foreach (var header in response.Headers.ToDictionary(x => x.Key, x => x.Value))
{
context.Response.AddHeader(header.Key, header.Value);
}
- foreach(var cookie in response.Cookies)
+ foreach(var cookie in response.Cookies.ToArray())
{
context.Response.AddHeader("Set-Cookie", cookie.ToString());
}

0 comments on commit dab5592

Please sign in to comment.
Something went wrong with that request. Please try again.