diff --git a/drama/routes/posts.py b/drama/routes/posts.py index db3062335..3bab0530b 100644 --- a/drama/routes/posts.py +++ b/drama/routes/posts.py @@ -96,6 +96,8 @@ def submit_get(v): b = get_guild("general") + resize() + return render_template("submit.html", v=v, b=b @@ -274,8 +276,6 @@ def edit_post(pid, v): for x in notify_users: send_notification(1046, x, f"@{v.username} has mentioned you: https://rdrama.net{p.permalink}") - resize() - return redirect(p.permalink) @app.route("/submit/title", methods=['GET']) @@ -1050,8 +1050,6 @@ def submit_post(v): g.db.add(n) g.db.commit() send_message(f"https://rdrama.net{new_post.permalink}") - - resize() return {"html": lambda: redirect(new_post.permalink), "api": lambda: jsonify(new_post.json) @@ -1077,8 +1075,6 @@ def delete_post_pid(pid, v): cache.delete_memoized(frontlist) - resize() - return "", 204 @app.route("/undelete_post/", methods=["POST"]) diff --git a/drama/routes/users.py b/drama/routes/users.py index 69172bf22..c8b747d30 100644 --- a/drama/routes/users.py +++ b/drama/routes/users.py @@ -10,7 +10,6 @@ from drama.mail import * from flask import * from drama.__main__ import app, cache, limiter, db_session from pusher_push_notifications import PushNotifications -from .posts import resize PUSHER_KEY = environ.get("PUSHER_KEY", "").strip()