From 2587d67765cd8279ca1a9f430fb7c74ef32df611 Mon Sep 17 00:00:00 2001 From: Kailash Nadh Date: Sat, 1 Aug 2020 13:21:28 +0530 Subject: [PATCH] Fix template creation API returning incorrect response --- templates.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates.go b/templates.go index bcf3dd7..c0b24b9 100644 --- a/templates.go +++ b/templates.go @@ -149,7 +149,7 @@ func handleCreateTemplate(c echo.Context) error { // Hand over to the GET handler to return the last insertion. c.SetParamNames("id") c.SetParamValues(fmt.Sprintf("%d", newID)) - return c.JSON(http.StatusOK, handleGetLists(c)) + return handleGetTemplates(c) } // handleUpdateTemplate handles template modification.