Bitbucket webhooks 💩 💩

remotes/origin/issue/4795/notification_even_they_are_disabled
David Barragán Merino 2016-04-01 10:34:27 +02:00
parent 28efb6dd68
commit bca10ae245
1 changed files with 7 additions and 10 deletions

View File

@ -40,15 +40,12 @@ class PushEventHook(BaseEventHook):
changes = self.payload.get("push", {}).get('changes', []) changes = self.payload.get("push", {}).get('changes', [])
for change in filter(None, changes): for change in filter(None, changes):
new = change.get("new", None) commits = target.get("commits", [])
if not new: if not commits:
continue continue
target = new.get("target", None) for commit in commits:
if not target: message = commit.get("message", None)
continue
message = target.get("message", None)
if not message: if not message:
continue continue