Added .Header(..), .ContentType(..) to HttpResponse
ln.build - build0.waldrennach.l--n.de build job pending Details

master
Harald Wolff 2020-12-12 20:49:40 +01:00
parent 16dbf87c66
commit c0ee1af74c
1 changed files with 10 additions and 1 deletions

View File

@ -115,7 +115,16 @@ namespace ln.http
get => HttpStatusCode.ToString();
}
public HttpResponse Header(string name,string value)
{
SetHeader(name, value);
return this;
}
public HttpResponse ContentType(string contentType)
{
SetHeader("content-type", contentType);
return this;
}
public static HttpResponse OK() => new HttpResponse(HttpStatusCode.OK);