update components

This commit is contained in:
Luke Pulverenti
2016-11-12 20:53:51 -05:00
parent 38c216a61a
commit 3e06bda46b
3 changed files with 8 additions and 37 deletions

View File

@@ -161,10 +161,8 @@ namespace ServiceStack
var responseText = result as string;
if (responseText != null)
{
if (response.ContentType == null || response.ContentType == "text/html")
response.ContentType = defaultContentType;
var bytes = Encoding.UTF8.GetBytes(responseText);
response.SetContentLength(bytes.Length);
await response.OutputStream.WriteAsync(bytes, 0, bytes.Length).ConfigureAwait(false);
return;
}