mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 15:27:13 +03:00
templater: retain author's full name if no email is supplied (issue1685)
This commit is contained in:
parent
5912c48b40
commit
47e33d1f81
@ -96,6 +96,7 @@ def domain(author):
|
|||||||
|
|
||||||
def person(author):
|
def person(author):
|
||||||
'''get name of author, or else username.'''
|
'''get name of author, or else username.'''
|
||||||
|
if not '@' in author: return author
|
||||||
f = author.find('<')
|
f = author.find('<')
|
||||||
if f == -1: return util.shortuser(author)
|
if f == -1: return util.shortuser(author)
|
||||||
return author[:f].rstrip()
|
return author[:f].rstrip()
|
||||||
|
Loading…
Reference in New Issue
Block a user