mirror of
https://github.com/go-gitea/gitea
synced 2025-07-22 18:28:37 +00:00
#1146 finish new access rights for collaborators
This commit is contained in:
@@ -490,7 +490,7 @@ func ParseCompareInfo(ctx *middleware.Context) (*models.User, *models.Repository
|
||||
}
|
||||
}
|
||||
|
||||
if !ctx.User.CanWriteTo(headRepo) && !ctx.User.IsAdmin {
|
||||
if !ctx.User.IsWriterOfRepo(headRepo) && !ctx.User.IsAdmin {
|
||||
log.Trace("ParseCompareInfo[%d]: does not have write access or site admin", baseRepo.ID)
|
||||
ctx.Handle(404, "ParseCompareInfo", nil)
|
||||
return nil, nil, nil, nil, "", ""
|
||||
|
Reference in New Issue
Block a user