mirror of
https://github.com/go-gitea/gitea.git
synced 2026-10-08 09:53:10 +02:00
fix admin lost permission caused by #947
This commit is contained in:
4 files changed
+14
-9
No files matched your search
+1
-1
@@ -250,7 +250,7 @@ func runServ(c *cli.Context) error {
|
||||
user.Name, requestedMode, repoPath)
|
||||
}
|
||||
|
||||
if !repo.CheckUnitUser(user.ID, unitType) {
|
||||
if !repo.CheckUnitUser(user.ID, user.IsAdmin, unitType) {
|
||||
fail("You do not have allowed for this action",
|
||||
"User %s does not have allowed access to repository %s 's code",
|
||||
user.Name, repoPath)
|
||||
|
||||
Reference in new issue
Block a user