From 442e3e44de9c685bae67c327dbe1714a68bcc547 Mon Sep 17 00:00:00 2001 From: Adhityaa Date: Mon, 11 Jun 2018 00:16:19 +0530 Subject: [PATCH] owner_new.go: create commenter user on ownerNew --- api/owner_new.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/api/owner_new.go b/api/owner_new.go index 85ba088..d8e7279 100644 --- a/api/owner_new.go +++ b/api/owner_new.go @@ -79,5 +79,10 @@ func ownerNewHandler(w http.ResponseWriter, r *http.Request) { return } + if _, err := commenterNew(*x.Email, *x.Name, "undefined", "undefined", "commento", *x.Password); err != nil { + writeBody(w, response{"success": false, "message": err.Error()}) + return + } + writeBody(w, response{"success": true, "confirmEmail": smtpConfigured}) }