20 lines
398 B
C#
20 lines
398 B
C#
using ln.json;
|
|
|
|
namespace ln.http.api
|
|
{
|
|
|
|
public static class HttpResponseExtensions
|
|
{
|
|
|
|
public static HttpResponse Content(this HttpResponse response, JSONValue json)
|
|
{
|
|
response.ContentType("application/json");
|
|
response.ContentWriter.Write(json.ToString());
|
|
response.ContentWriter.Flush();
|
|
return response;
|
|
}
|
|
|
|
}
|
|
|
|
}
|