diff --git a/buildtrigger/bitbuckethandler.py b/buildtrigger/bitbuckethandler.py index adb7e10d1..089271355 100644 --- a/buildtrigger/bitbuckethandler.py +++ b/buildtrigger/bitbuckethandler.py @@ -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']