diff options
Diffstat (limited to 'routers/api/v1/repo/repo.go')
-rw-r--r-- | routers/api/v1/repo/repo.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/routers/api/v1/repo/repo.go b/routers/api/v1/repo/repo.go index a43246624e..317b0c57a1 100644 --- a/routers/api/v1/repo/repo.go +++ b/routers/api/v1/repo/repo.go @@ -64,7 +64,7 @@ func Search(ctx *context.APIContext) { }) return } - accessMode, err := models.AccessLevel(ctx.User, repo) + accessMode, err := models.AccessLevel(ctx.User.ID, repo) if err != nil { ctx.JSON(500, map[string]interface{}{ "ok": false, @@ -218,7 +218,7 @@ func Migrate(ctx *context.APIContext, form auth.MigrateRepoForm) { // see https://github.com/gogits/go-gogs-client/wiki/Repositories#get func Get(ctx *context.APIContext) { repo := ctx.Repo.Repository - access, err := models.AccessLevel(ctx.User, repo) + access, err := models.AccessLevel(ctx.User.ID, repo) if err != nil { ctx.Error(500, "GetRepository", err) return @@ -238,7 +238,7 @@ func GetByID(ctx *context.APIContext) { return } - access, err := models.AccessLevel(ctx.User, repo) + access, err := models.AccessLevel(ctx.User.ID, repo) if err != nil { ctx.Error(500, "GetRepositoryByID", err) return |