Prior to this change, if a user enabled GitHub webhooks for "create" events in GitHub (eg tag creations), then Copr would not rebuild packages for those webhooks.
In this case "ref" is not a branch name, but a Git tag. We should not attempt to compare this tag name to the branch name in the commits_belong_to_package() method.
Prior to this change, if a user enabled GitHub webhooks for "create" events in GitHub (eg tag creations), then Copr would not rebuild packages for those webhooks.
From https://developer.github.com/v3/activity/events/types/#createevent, the "tag creation" webhook looks like so:
In this case "
ref
" is not a branch name, but a Git tag. We should not attempt to compare this tag name to the branch name in thecommits_belong_to_package()
method.