aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
Diffstat (limited to 'modules')
-rw-r--r--modules/git_webhooks/gitlab.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/git_webhooks/gitlab.py b/modules/git_webhooks/gitlab.py
index 644ce823..19d17ea9 100644
--- a/modules/git_webhooks/gitlab.py
+++ b/modules/git_webhooks/gitlab.py
@@ -50,9 +50,9 @@ ISSUE_ACTIONS = {
class GitLab(object):
def is_private(self, data, headers):
- if "project" in data:
+ if "visibility_level" in data.get("project", {}):
return not data["project"]["visibility_level"] == 20
- return False
+ return data.get("repository", {}).get("private", False)
def names(self, data, headers):
full_name = data["project"]["path_with_namespace"]