From 199faadea3ff40880d70c8bc031aab800720330d Mon Sep 17 00:00:00 2001 From: Lunny Xiao Date: Fri, 26 Apr 2019 02:59:10 +0800 Subject: Fix org visibility bug when git cloning (#6743) * fix org visibility bug * fix permission check * add integration tests * fix tests * change test user name for easier maintainance and fix test * fix test git repo name --- modules/context/repo.go | 6 ------ 1 file changed, 6 deletions(-) (limited to 'modules/context/repo.go') diff --git a/modules/context/repo.go b/modules/context/repo.go index 770296b390..f9ed9327ff 100644 --- a/modules/context/repo.go +++ b/modules/context/repo.go @@ -236,12 +236,6 @@ func repoAssignment(ctx *Context, repo *models.Repository) { return } - if repo.Owner.IsOrganization() { - if !models.HasOrgVisible(repo.Owner, ctx.User) { - ctx.NotFound("HasOrgVisible", nil) - return - } - } ctx.Repo.Permission, err = models.GetUserRepoPermission(repo, ctx.User) if err != nil { ctx.ServerError("GetUserRepoPermission", err) -- cgit v1.2.3