diff options
author | Unknown <joe2010xtmf@163.com> | 2014-02-19 13:13:02 -0500 |
---|---|---|
committer | Unknown <joe2010xtmf@163.com> | 2014-02-19 13:13:02 -0500 |
commit | d87ea87aee883b073ff198902c0439a19ff707e5 (patch) | |
tree | f46a623188a0f4a4dc0ea1a7026778aa0ad79237 /routers | |
parent | 4b92a6c2df28054ad766bc262f308db9f6066596 (diff) | |
download | gitea-d87ea87aee883b073ff198902c0439a19ff707e5.tar.gz gitea-d87ea87aee883b073ff198902c0439a19ff707e5.zip |
Add code of delete user
Diffstat (limited to 'routers')
-rw-r--r-- | routers/user/user.go | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/routers/user/user.go b/routers/user/user.go index 24c22a4f44..3566601200 100644 --- a/routers/user/user.go +++ b/routers/user/user.go @@ -51,3 +51,11 @@ func SignUp(req *http.Request, r render.Render) { "Title": fmt.Sprintf("%v", err), }) } + +func Delete(r render.Render) { + u := &models.User{} + err := models.DeleteUser(u) + r.HTML(403, "status/403", map[string]interface{}{ + "Title": fmt.Sprintf("%v", err), + }) +} |