summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorubq323 <ubq323>2021-06-14 20:22:50 +0000
committerubq323 <ubq323>2021-06-14 20:22:50 +0000
commit93d9da49abfb980951265aeaee9a2cf251bc1044 (patch)
treeb1cacc93530347098a7a1dc0115c8bf4034647d3
parenta3b9a43a626966ec0885a0882a4d7f5ee3221803 (diff)
hide config thread button if you wouldn't be able to access it anywayconfig_thread
-rw-r--r--apioforum/templates/view_thread.html4
1 files changed, 3 insertions, 1 deletions
diff --git a/apioforum/templates/view_thread.html b/apioforum/templates/view_thread.html
index ddc45b8..eaaf581 100644
--- a/apioforum/templates/view_thread.html
+++ b/apioforum/templates/view_thread.html
@@ -5,7 +5,9 @@
{% endblock %}
{%block content%}
-<a class="actionbutton" href="{{url_for('thread.config_thread',thread_id=thread_id)}}">configure</a>
+{% if g.user == thread.creator %}
+<a class="actionbutton" href="{{url_for('thread.config_thread',thread_id=thread_id)}}">configure thread</a>
+{% endif %}
<div class="posts">
{% for post in posts %}
{% call disp_post(post, True) %}