@@ -458,49 +458,49 @@ def fmt_date(date):
def is_git(repository):
if hasattr(repository, 'alias'):
_type = repository.alias
elif hasattr(repository, 'repo_type'):
_type = repository.repo_type
else:
_type = repository
return _type == 'git'
def is_hg(repository):
return _type == 'hg'
def user_or_none(author):
email = author_email(author)
if email is not None:
if email:
user = User.get_by_email(email, case_insensitive=True, cache=True)
if user is not None:
return user
user = User.get_by_username(author_name(author), case_insensitive=True, cache=True)
return None
def email_or_none(author):
if not author:
user = user_or_none(author)
return user.email # always use main email address - not necessarily the one used to find user
# extract email from the commit string
return email
# No valid email, not a valid user in the system, none!
Status change: