Example #1
0
func getProjects(params martini.Params, r render.Render, m model.Model) {
	if name := params["name"]; name != "" {
		r.JSON(200, m.User(name).Projects)
	} else {
		r.JSON(200, m.User("zephyyrr").Projects)

	}

}
Example #2
0
func getUser(params martini.Params, r render.Render, m model.Model) {
	r.JSON(200, m.User(params["name"]))
}
Example #3
0
func getUsers(r render.Render, m model.Model) {
	r.JSON(200, m.Users())
}