MCPcopy Create free account
hub / github.com/gogs/gogs / responseAPIUsers

Function responseAPIUsers

internal/route/api/v1/user/follower.go:10–16  ·  view source on GitHub ↗
(c *context.APIContext, users []*database.User)

Source from the content-addressed store, hash-verified

8)
9
10func responseAPIUsers(c *context.APIContext, users []*database.User) {
11 apiUsers := make([]*api.User, len(users))
12 for i := range users {
13 apiUsers[i] = users[i].APIFormat()
14 }
15 c.JSONSuccess(&apiUsers)
16}
17
18func listUserFollowers(c *context.APIContext, u *database.User) {
19 users, err := database.Handle.Users().ListFollowers(c.Req.Context(), u.ID, c.QueryInt("page"), database.ItemsPerPage)

Callers 2

listUserFollowersFunction · 0.85
listUserFollowingFunction · 0.85

Calls 2

JSONSuccessMethod · 0.80
APIFormatMethod · 0.45

Tested by

no test coverage detected