Add API handler for /users/self

This commit is contained in:
Howl
2016-04-05 22:38:33 +02:00
parent d02f3f9951
commit b484fe2761
2 changed files with 11 additions and 0 deletions

View File

@@ -28,6 +28,7 @@ func Start(conf common.Conf, db *sql.DB) {
// Read privilege required
gv1.GET("/users/id/:id", Method(v1.UserByIDGET, db, common.PrivilegeRead))
gv1.GET("/users/name/:name", Method(v1.UserByNameGET, db, common.PrivilegeRead))
gv1.GET("/users/self", Method(v1.UserSelfGET, db, common.PrivilegeRead))
gv1.GET("/badges", Method(v1.BadgesGET, db, common.PrivilegeRead))
gv1.GET("/badges/:id", Method(v1.BadgeByIDGET, db, common.PrivilegeRead))
}