diff options
Diffstat (limited to 'routers/private/hook.go')
-rw-r--r-- | routers/private/hook.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/routers/private/hook.go b/routers/private/hook.go index c9065bceb3..2644302ead 100644 --- a/routers/private/hook.go +++ b/routers/private/hook.go @@ -98,7 +98,7 @@ func HookPreReceive(ctx *macaron.Context) { canPush := false if isDeployKey { - canPush = protectBranch.WhitelistDeployKeys + canPush = protectBranch.CanPush && (!protectBranch.EnableWhitelist || protectBranch.WhitelistDeployKeys) } else { canPush = protectBranch.CanUserPush(userID) } |