From fb7db7719fa7002c5569bc03b24096f15ca51dc6 Mon Sep 17 00:00:00 2001 From: Jeffrey Paul Date: Fri, 8 Nov 2019 04:41:18 -0800 Subject: [PATCH] fix output bug --- merp.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/merp.go b/merp.go index d4527e3..44048fa 100644 --- a/merp.go +++ b/merp.go @@ -47,7 +47,7 @@ func getLatestMerps() gin.HandlerFunc { qs := orm.QueryTable("merp").Filter("thing", thing).OrderBy("-created").Limit(50) qs.All(&merps) - var output []map[string]interface{} + output := make([]map[string]interface{}, 0) for _, merp := range merps { outelem := make(map[string]interface{}) outelem["thing"] = merp.Thing