1. Olemis Lang
  2. bloodhound-trac


bloodhound-trac / trac / templates / author_or_creator.rss

<?xml version="1.0"?>
Generate an <author> or a <dc:creator> tag, based on the presence
of an email or not in the author's information.

 - author: the author to be used
 - email_map=None: a mapping from login to e-mail address
<rss version="2.0"
     py:with="email_map = value_of('email_map', None)" py:strip="">
  <py:if test="author">
    <!--! Try our best to retrieve an email address if wanted and possible -->
    <py:with vars="author = email_map[author] if show_email_addresses and email_map and '@' not in author else author">
        <author py:when="show_email_addresses and '@' in author">${format_author(author)}</author>
        <dc:creator py:otherwise="">${format_author(author)}</dc:creator>