summaryrefslogtreecommitdiffstats
path: root/routers
diff options
context:
space:
mode:
authorLunny Xiao <xiaolunwen@gmail.com>2017-01-03 12:41:10 +0800
committerGitHub <noreply@github.com>2017-01-03 12:41:10 +0800
commit70900bd16724ccb73d8b69e830f046b4815c9595 (patch)
tree82b4c8de5aac439c9661d675e0a1eb8b79a9ecdd /routers
parent51021585a7d7623696ad90ab0ea3b2658c8da2bb (diff)
downloadgitea-70900bd16724ccb73d8b69e830f046b4815c9595.tar.gz
gitea-70900bd16724ccb73d8b69e830f046b4815c9595.zip
bug fixed for fork repos (#560)
Diffstat (limited to 'routers')
-rw-r--r--routers/repo/pull.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/repo/pull.go b/routers/repo/pull.go
index 5e51fda495..583f3b0a35 100644
--- a/routers/repo/pull.go
+++ b/routers/repo/pull.go
@@ -48,7 +48,7 @@ func getForkRepository(ctx *context.Context) *models.Repository {
return nil
}
- if !forkRepo.CanBeForked() {
+ if !forkRepo.CanBeForked() || !forkRepo.HasAccess(ctx.User) {
ctx.Handle(404, "getForkRepository", nil)
return nil
}