Browse Source

Fix incorrect logic check for fork repo action

pull/3996/head
Unknwon 8 years ago
parent
commit
cdfcef04a1
No known key found for this signature in database
GPG Key ID: 7A02C406FAC875A2
  1. 3
      routers/repo/pull.go

3
routers/repo/pull.go

@ -49,7 +49,8 @@ func getForkRepository(ctx *context.Context) *models.Repository {
return nil
}
if !forkRepo.CanBeForked() || !ctx.Repo.HasAccess() {
hasAccess, _ := models.HasAccess(ctx.User, forkRepo, models.ACCESS_MODE_READ)
if !hasAccess || !forkRepo.CanBeForked() {
ctx.Handle(404, "getForkRepository", nil)
return nil
}

Loading…
Cancel
Save