

@presentation.render_for(Board, 'num_matches')
def render_Board_num_matches(self, h, comp, *args):
    if self.card_matches:
        if (None in self.card_matches):
            (h << h.span(_('No matches'), class_='nomatches'))
        else:
            n = len(self.card_matches)
            (h << (_N('%d match', '%d matches', n) % n))
    else:
        (h << ' ')
    return h.root

dataset/ETHPy150Open Net-ng/kansha/kansha/board/view.py render_Board_num_matches/original