Allow nonexistent releases in default_data
Each "repos" data can contain the list of releases. If not containing releases, TypeError happens on current code. This patch makes the code allow nonexistent releases instead of the exception. Change-Id: I264784bdfbd016cbd0225a0604d03acfe5ecf967
This commit is contained in:
@@ -111,7 +111,7 @@ def _process_repo(repo, runtime_storage_inst, record_processor_inst,
|
||||
vcs_inst.fetch()
|
||||
|
||||
branches = {repo.get('default_branch', 'master')}
|
||||
for release in repo.get('releases'):
|
||||
for release in repo.get('releases', []):
|
||||
if 'branch' in release:
|
||||
branches.add(release['branch'])
|
||||
|
||||
|
||||
Reference in New Issue
Block a user