diff --git a/drama/helpers/sanitize.py b/drama/helpers/sanitize.py index 2ad979376..a01dea623 100644 --- a/drama/helpers/sanitize.py +++ b/drama/helpers/sanitize.py @@ -189,7 +189,7 @@ def sanitize(text, linkgen=False, flair=False): if flair: emojisize = 20 else: emojisize = 30 for i in re.finditer(':(.{1,30}?):', sanitized): - if path.isfile(f'/d/drama/assets/images/emojis/{i.group(1)}.gif'): + if path.isfile(f'./drama/assets/images/emojis/{i.group(1)}.gif'): sanitized = sanitized.replace(f':{i.group(1)}:', f'') sanitized = sanitized.replace("https://www.", "https://").replace("https://youtu.be/", "https://youtube.com/embed/").replace("https://music.youtube.com/watch?v=", "https://youtube.com/embed/").replace("/watch?v=", "/embed/").replace("https://open.spotify.com/", "https://open.spotify.com/embed/").replace("https://streamable.com/", "https://streamable.com/e/").replace("https://youtube.com/shorts/", "https://youtube.com/embed/") diff --git a/drama/routes/admin.py b/drama/routes/admin.py index de3c7d07f..3b8de59e5 100644 --- a/drama/routes/admin.py +++ b/drama/routes/admin.py @@ -2,7 +2,7 @@ import time import calendar from sqlalchemy.orm import lazyload import imagehash -from os import remove, getcwd +from os import remove from PIL import Image as IMAGE from drama.helpers.wrappers import * @@ -119,7 +119,6 @@ def flagged_comments(v): @app.route("/admin", methods=["GET"]) @admin_level_required(3) def admin_home(v): - print(getcwd()) with open('./disablesignups', 'r') as f: x = f.read() return render_template("admin/admin_home.html", v=v, x=x) diff --git a/drama/templates/admin/admin_home.html b/drama/templates/admin/admin_home.html index ed391a883..ebfe2c2e4 100644 --- a/drama/templates/admin/admin_home.html +++ b/drama/templates/admin/admin_home.html @@ -29,9 +29,9 @@ {% endfilter %} -{#
+
-
#} +
{% endblock %} \ No newline at end of file