1
0
Fork 0
mirror of https://gitlab.com/SIGBUS/nyaa.git synced 2024-12-22 20:19:59 +00:00

Fancy grammar in your anime torrents

This commit is contained in:
TheAMM 2017-05-24 21:54:50 +03:00
parent d287aaf974
commit 4f1576e086
2 changed files with 3 additions and 2 deletions

View file

@ -57,7 +57,8 @@
</button> </button>
<a class="navbar-brand" href="/">{{ config.SITE_NAME }}</a> <a class="navbar-brand" href="/">{{ config.SITE_NAME }}</a>
</div> </div>
{% set search_placeholder = 'Search {}\'s torrents...'.format(user.username) if user_page else 'Search...' %} {% set search_username = (user.username + ("'" if user.username[-1] == 's' else "'s")) if user_page else None %}
{% set search_placeholder = 'Search {} torrents...'.format(search_username) if user_page else 'Search...' %}
<div id="navbar" class="navbar-collapse collapse"> <div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav"> <ul class="nav navbar-nav">
<li {% if request.path == "/upload" %} class="active"{% endif %}><a href="/upload">Upload</a></li> <li {% if request.path == "/upload" %} class="active"{% endif %}><a href="/upload">Upload</a></li>

View file

@ -41,7 +41,7 @@
{% endif %} {% endif %}
<h3> <h3>
Browsing <span class="text-{{ user.userlevel_color }}">{{ user.username }}</span>'s torrents Browsing <span class="text-{{ user.userlevel_color }}">{{ user.username }}</span>'{{ '' if user.username[-1] == 's' else 's' }} torrents
</h3> </h3>
{% include "search_results.html" %} {% include "search_results.html" %}