diff options
author | Unknwon <u@gogs.io> | 2016-07-24 01:08:22 +0800 |
---|---|---|
committer | Unknwon <u@gogs.io> | 2016-07-24 01:08:22 +0800 |
commit | 1f2e173a745da8e4b57f96b5561a3c10054d3b76 (patch) | |
tree | 367f0f07e4fe1269ac0772e0561a4bf912b5153c /routers/api/v1/user/follower.go | |
parent | 46e96c008cf966428c9dad71c7871de88186e3fe (diff) |
Refactor User.Id to User.ID
Diffstat (limited to 'routers/api/v1/user/follower.go')
-rw-r--r-- | routers/api/v1/user/follower.go | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/routers/api/v1/user/follower.go b/routers/api/v1/user/follower.go index 00d1952d..8d103c9e 100644 --- a/routers/api/v1/user/follower.go +++ b/routers/api/v1/user/follower.go @@ -78,7 +78,7 @@ func CheckMyFollowing(ctx *context.APIContext) { if ctx.Written() { return } - checkUserFollowing(ctx, ctx.User, target.Id) + checkUserFollowing(ctx, ctx.User, target.ID) } // https://github.com/gogits/go-gogs-client/wiki/Users-Followers#check-if-one-user-follows-another @@ -91,7 +91,7 @@ func CheckFollowing(ctx *context.APIContext) { if ctx.Written() { return } - checkUserFollowing(ctx, u, target.Id) + checkUserFollowing(ctx, u, target.ID) } // https://github.com/gogits/go-gogs-client/wiki/Users-Followers#follow-a-user @@ -100,7 +100,7 @@ func Follow(ctx *context.APIContext) { if ctx.Written() { return } - if err := models.FollowUser(ctx.User.Id, target.Id); err != nil { + if err := models.FollowUser(ctx.User.ID, target.ID); err != nil { ctx.Error(500, "FollowUser", err) return } @@ -113,7 +113,7 @@ func Unfollow(ctx *context.APIContext) { if ctx.Written() { return } - if err := models.UnfollowUser(ctx.User.Id, target.Id); err != nil { + if err := models.UnfollowUser(ctx.User.ID, target.ID); err != nil { ctx.Error(500, "UnfollowUser", err) return } |