diff --git a/files/routes/posts.py b/files/routes/posts.py index e81596161..ee17e6c4d 100644 --- a/files/routes/posts.py +++ b/files/routes/posts.py @@ -414,7 +414,9 @@ def morecomments(v, cid): c = g.db.query(Comment).filter_by(id=cid).one_or_none() comments = c.replies - p = comments[0].post + if comments: p = comments[0].post + else: p = None + return render_template("comments.html", v=v, comments=comments, p=p, render_replies=True, ajax=True) @app.post("/edit_post/") diff --git a/files/routes/settings.py b/files/routes/settings.py index fb21a7dc6..df5c8ebbc 100644 --- a/files/routes/settings.py +++ b/files/routes/settings.py @@ -309,7 +309,7 @@ def settings_profile_post(v): defaultsorting = request.values.get("defaultsorting") if defaultsorting: - if defaultsorting in {"hot", "new", "old", "comments", "controversial", "top", "bottom"}: + if defaultsorting in {"hot", "bump", "new", "old", "comments", "controversial", "top", "bottom"}: v.defaultsorting = defaultsorting updated = True else: abort(400) diff --git a/files/templates/authforms.html b/files/templates/authforms.html index 6397b3957..06a0d201e 100644 --- a/files/templates/authforms.html +++ b/files/templates/authforms.html @@ -15,7 +15,7 @@ {% if v %} - + {% if v.agendaposter %} - + {% endif %} diff --git a/files/templates/default.html b/files/templates/default.html index fae0d078e..89bfbb0ed 100644 --- a/files/templates/default.html +++ b/files/templates/default.html @@ -8,7 +8,7 @@ {% if v %} - + {% if v.agendaposter %} - + {% endif %} {% if sub and sub.css and not request.path.endswith('settings') %} diff --git a/files/templates/log.html b/files/templates/log.html index 9ff5f3d1e..2dc42bab9 100644 --- a/files/templates/log.html +++ b/files/templates/log.html @@ -6,7 +6,7 @@ {% block content %} {% if v %} - + {% if v.agendaposter %} - + {% endif %}
diff --git a/files/templates/login.html b/files/templates/login.html index 34d1a4e69..ea8aa9ed4 100644 --- a/files/templates/login.html +++ b/files/templates/login.html @@ -19,7 +19,7 @@ - + diff --git a/files/templates/login_2fa.html b/files/templates/login_2fa.html index 334ae5355..99d59d977 100644 --- a/files/templates/login_2fa.html +++ b/files/templates/login_2fa.html @@ -14,7 +14,7 @@ 2-Step Login - {{SITE_NAME}} - + diff --git a/files/templates/settings.html b/files/templates/settings.html index 6529b0a23..8d108d8d9 100644 --- a/files/templates/settings.html +++ b/files/templates/settings.html @@ -34,7 +34,7 @@ - + {% if v.agendaposter %} - + {% else %} - + {% endif %} diff --git a/files/templates/settings_filters.html b/files/templates/settings_filters.html index 242b594d6..2678b4598 100644 --- a/files/templates/settings_filters.html +++ b/files/templates/settings_filters.html @@ -67,7 +67,7 @@

Change the default sorting for posts.

diff --git a/files/templates/sign_up.html b/files/templates/sign_up.html index 923719eb5..eba60bf40 100644 --- a/files/templates/sign_up.html +++ b/files/templates/sign_up.html @@ -31,7 +31,7 @@ {% if ref_user %}{{ref_user.username}} invites you to {{SITE_NAME}}{% else %}Sign up - {{SITE_NAME}}{% endif %} - + diff --git a/files/templates/sign_up_failed_ref.html b/files/templates/sign_up_failed_ref.html index 14c82e5a4..b6536ca8c 100644 --- a/files/templates/sign_up_failed_ref.html +++ b/files/templates/sign_up_failed_ref.html @@ -32,7 +32,7 @@ {% if ref_user %}{{ref_user.username}} invites you to {{SITE_NAME}}{% else %}{{SITE_NAME}}{% endif %} - + diff --git a/files/templates/submission_listing.html b/files/templates/submission_listing.html index f10da6662..9a779a1b2 100644 --- a/files/templates/submission_listing.html +++ b/files/templates/submission_listing.html @@ -205,7 +205,7 @@   {{p.views}} thread views
-
+
{% if p.club %}{{CC}}{% endif %} {% if p.flair %}{{p.flair | safe}}{% endif %} {{p.realtitle(v) | safe}} diff --git a/files/templates/submit.html b/files/templates/submit.html index 7c81f2427..d335b1aae 100644 --- a/files/templates/submit.html +++ b/files/templates/submit.html @@ -26,7 +26,7 @@ {% block stylesheets %} {% if v %} - + {% if v.agendaposter %} - + {% endif %} {% endblock %}