public static async Task WriteJsonAsync(this HttpResponse response, object o) { var json = ObjectSerializer.ToString(o); await response.WriteJsonAsync(json); }
public static async Task WriteJsonAsync(this HttpResponse response, object o, string contentType = null) { var json = ObjectSerializer.ToString(o); await response.WriteJsonAsync(json, contentType); }