##// END OF EJS Templates
Make rhodecode use author/username filter from vcs instead of mercurial
marcink -
r1356:eec4defd beta
parent child Browse files
Show More
@@ -317,21 +317,17 def is_following_repo(repo_name, user_id
317
317
318 flash = _Flash()
318 flash = _Flash()
319
319
320
321 #==============================================================================
320 #==============================================================================
322 # MERCURIAL FILTERS available via h.
321 # SCM FILTERS available via h.
323 #==============================================================================
322 #==============================================================================
324 from mercurial import util
323 from vcs.utils import author_name, author_email
325 from mercurial.templatefilters import person as _person
326 from rhodecode.lib import credentials_hidder, age as _age
324 from rhodecode.lib import credentials_hidder, age as _age
327
325
328
329
330 age = lambda x:_age(x)
326 age = lambda x:_age(x)
331 capitalize = lambda x: x.capitalize()
327 capitalize = lambda x: x.capitalize()
332 email = util.email
328 email = author_email
333 email_or_none = lambda x: util.email(x) if util.email(x) != x else None
329 email_or_none = lambda x: email(x) if email(x) != x else None
334 person = lambda x: _person(x)
330 person = lambda x: author_name(x)
335 short_id = lambda x: x[:12]
331 short_id = lambda x: x[:12]
336 hide_credentials = lambda x: ''.join(credentials_hidder(x))
332 hide_credentials = lambda x: ''.join(credentials_hidder(x))
337
333
General Comments 0
You need to be logged in to leave comments. Login now