mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-22 01:34:18 +00:00
#1146 finish new access rights for collaborators
This commit is contained in:
parent
045f14fbd0
commit
a5b0400be7
22 changed files with 210 additions and 190 deletions
|
@ -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, "", ""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue