fix handling missing authors for Bitbucket
The author was accidentally always being initialized as a JSONPathDict, thus the `if` expression following was always true. Fixes #733.
This commit is contained in:
parent
b7f8fc86f4
commit
c7fba332e6
1 changed files with 2 additions and 2 deletions
|
@ -200,8 +200,8 @@ def get_transformed_commit_info(bb_commit, ref, default_branch, repository_name,
|
|||
|
||||
match = _RAW_AUTHOR_REGEX.match(commit['raw_author'])
|
||||
if match:
|
||||
email_address = match.group(1)
|
||||
author_info = JSONPathDict(lookup_author(email_address))
|
||||
author = lookup_author(match.group(1))
|
||||
author_info = JSONPathDict(author) if author is not None else None
|
||||
if author_info:
|
||||
config['commit_info.author.username'] = author_info['user.username']
|
||||
config['commit_info.author.url'] = 'https://bitbucket.org/%s/' % author_info['user.username']
|
||||
|
|
Reference in a new issue