Skip to content

Commit

Permalink
Use safer HeaderDictionaryExtensions (#14064)
Browse files Browse the repository at this point in the history
  • Loading branch information
jtkech authored Aug 4, 2023
1 parent 9db3db9 commit 16d9fb3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ public override async Task<ActivityExecutionResult> ExecuteAsync(WorkflowExecuti

foreach (var header in headers)
{
response.Headers.Add(header);
response.Headers.Append(header.Key, header.Value);
}

if (!String.IsNullOrWhiteSpace(contentType))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public async Task Invoke(HttpContext httpContext)
{
if (shellSettings.IsInitializing())
{
httpContext.Response.Headers.Add(HeaderNames.RetryAfter, "10");
httpContext.Response.Headers.Append(HeaderNames.RetryAfter, "10");
httpContext.Response.StatusCode = StatusCodes.Status503ServiceUnavailable;
await httpContext.Response.WriteAsync("The requested tenant is currently initializing.");
return;
Expand Down

0 comments on commit 16d9fb3

Please sign in to comment.