parent
1346b7fb63
commit
8c78d967f8
1 changed files with 4 additions and 2 deletions
|
@ -358,10 +358,13 @@ class GithubBuildTrigger(BuildTriggerHandler):
|
||||||
[{'kind': 'tag', 'name': tag} for tag in tags])
|
[{'kind': 'tag', 'name': tag} for tag in tags])
|
||||||
|
|
||||||
config = self.config
|
config = self.config
|
||||||
|
source = config.get('build_source')
|
||||||
|
if source is None:
|
||||||
|
return []
|
||||||
|
|
||||||
if field_name == 'tag_name':
|
if field_name == 'tag_name':
|
||||||
try:
|
try:
|
||||||
gh_client = self._get_client()
|
gh_client = self._get_client()
|
||||||
source = config['build_source']
|
|
||||||
repo = gh_client.get_repo(source)
|
repo = gh_client.get_repo(source)
|
||||||
gh_tags = repo.get_tags()
|
gh_tags = repo.get_tags()
|
||||||
if limit:
|
if limit:
|
||||||
|
@ -378,7 +381,6 @@ class GithubBuildTrigger(BuildTriggerHandler):
|
||||||
if field_name == 'branch_name':
|
if field_name == 'branch_name':
|
||||||
try:
|
try:
|
||||||
gh_client = self._get_client()
|
gh_client = self._get_client()
|
||||||
source = config['build_source']
|
|
||||||
repo = gh_client.get_repo(source)
|
repo = gh_client.get_repo(source)
|
||||||
gh_branches = repo.get_branches()
|
gh_branches = repo.get_branches()
|
||||||
if limit:
|
if limit:
|
||||||
|
|
Reference in a new issue