aboutsummaryrefslogtreecommitdiff
path: root/src/main/resources/templates/views
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2023-01-22 14:14:58 +0300
committerGravatar Vitaly Takmazov2023-01-22 14:14:58 +0300
commit9ad08dc78e0cdbe2cdebf10a96c800e72d48e48b (patch)
tree25ef5787f8a77bd24c40490edaafe7d8a4697389 /src/main/resources/templates/views
parentd17e5714c9b421fce507d310fd913ce3160a1764 (diff)
Refactor messages service, remove 2 unneeded SQL queries
Diffstat (limited to 'src/main/resources/templates/views')
-rw-r--r--src/main/resources/templates/views/thread.html7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/main/resources/templates/views/thread.html b/src/main/resources/templates/views/thread.html
index 7aecaea4..759c47e1 100644
--- a/src/main/resources/templates/views/thread.html
+++ b/src/main/resources/templates/views/thread.html
@@ -102,18 +102,15 @@
</div>
</form>
{% endif %}
- {% if recomm is not empty %}
+ {% if msg.recommendations.size() > 0 %}
<div class="msg-recomms">{{ i18n("messages","message.recommendedBy") }}
- {% for rec in recomm %}
+ {% for rec in msg.recommendations %}
{% if rec.uri.toString() is empty %}
<a href="/{{ rec.name }}/">@{{ rec.name }}</a>{% if loop.index < (loop.length - 1) %}, {% endif %}
{% else %}
<a href="{{ rec.uri }}" data-user-uri="1">@{{ rec.name }}</a>{% if loop.index < (loop.length - 1) %}, {% endif %}
{% endif %}
{% endfor %}
- {% if msg.recommendations.size() > recomm.size() %}
- &nbsp;{{ i18n("messages","message.recommendedOthers", msg.recommendations.size() - recomm.size()) }}
- {% endif %}
</div>
{% endif %}
</div>