AccessControl: Fix locked role picker in orgs/edit page (#46539)

* AccessControl: Fix locked role picker in orgs/edit page

* Use correct org when computing metadata
This commit is contained in:
Gabriel MABILLE
2022-03-24 08:58:10 +01:00
committed by GitHub
parent a9b55f7905
commit 3440e7c8f7
7 changed files with 20 additions and 11 deletions
@@ -121,6 +121,9 @@ func AuthorizeInOrgMiddleware(ac accesscontrol.AccessControl, db sqlstore.Store)
}
authorize(c, ac, &userCopy, evaluator)
// Set the signed in user permissions in that org
c.SignedInUser.Permissions = userCopy.Permissions
}
}
}