finish the chat count commit

master
Aevann1 2022-08-13 09:45:57 +02:00
parent a51a2d2a1b
commit 6fe4a39908
1 changed files with 7 additions and 3 deletions

View File

@ -168,9 +168,13 @@
<li class="nav-item d-flex align-items-center justify-content-center text-center mx-1"> <li class="nav-item d-flex align-items-center justify-content-center text-center mx-1">
<a class="nav-link position-relative" href="/chat" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Chat"> <a class="nav-link position-relative" href="/chat" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Chat">
<i class="fas fa-messages"></i> <i class="fas fa-messages"></i>
<span class="notif-count bg-primary ml-1" style="padding-left: 4.5px;"> {% set chat_count = cache.get(ONLINE_STR) %}
{{cache.get(ONLINE_STR) or 0}}
</span> {% if chat_count %}
<span class="notif-count bg-primary ml-1" style="padding-left: 4.5px;" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Users in chat right now">
{{chat_count}}
</span>
{% endif %}
</a> </a>
</li> </li>
{%- endif %} {%- endif %}