diff --git a/files/classes/mod_logs.py b/files/classes/mod_logs.py
index 7fc7685e1a..0f972b70c1 100644
--- a/files/classes/mod_logs.py
+++ b/files/classes/mod_logs.py
@@ -280,6 +280,11 @@ ACTIONTYPES = {
"icon": 'fa-sack-dollar',
"color": 'bg-success'
},
+ 'move_hole': {
+ "str": 'moved {self.target_link} to /h/{self.target_post.sub}',
+ "icon": 'fa-manhole',
+ "color": 'bg-primary'
+ },
'nuke_user': {
"str": 'removed all content of {self.target_link}',
"icon": 'fa-radiation-alt',
diff --git a/files/routes/reporting.py b/files/routes/reporting.py
index fdb7f03bd4..d6ee042674 100644
--- a/files/routes/reporting.py
+++ b/files/routes/reporting.py
@@ -38,6 +38,15 @@ def api_flag_post(pid, v):
_note=f'"{post.flair}"'
)
g.db.add(ma)
+ elif reason.startswith('/h/') and v.admin_level > 2:
+ post.sub = reason[3:]
+ g.db.add(post)
+ ma=ModAction(
+ kind="move_hole",
+ user_id=v.id,
+ target_submission_id=post.id,
+ )
+ g.db.add(ma)
else:
flag = Flag(post_id=post.id, user_id=v.id, reason=reason)
g.db.add(flag)
diff --git a/files/routes/subs.py b/files/routes/subs.py
index 827360e47d..6107c72c42 100644
--- a/files/routes/subs.py
+++ b/files/routes/subs.py
@@ -271,7 +271,7 @@ def remove_mod(v, sub):
@app.get("/create_sub")
@is_not_permabanned
def create_sub(v):
- if SITE_NAME == 'rDrama' and v.id not in (AEVANN_ID, CARP_ID): abort(403)
+ if SITE_NAME == 'rDrama' and v.admin_level < 3: abort(403)
if request.host == 'rdrama.net': cost = 0
else:
@@ -286,7 +286,7 @@ def create_sub(v):
@app.post("/create_sub")
@is_not_permabanned
def create_sub2(v):
- if SITE_NAME == 'rDrama' and v.id not in (AEVANN_ID, CARP_ID): abort(403)
+ if SITE_NAME == 'rDrama' and v.admin_level < 3: abort(403)
name = request.values.get('name')
if not name: abort(400)
diff --git a/files/templates/authforms.html b/files/templates/authforms.html
index 9bb65334be..2e2c6180bb 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/chat.html b/files/templates/chat.html
index a346d4c1b9..ec67ab82e4 100644
--- a/files/templates/chat.html
+++ b/files/templates/chat.html
@@ -14,7 +14,7 @@
Chat
-
+
{% if v.css %}
diff --git a/files/templates/default.html b/files/templates/default.html
index 964b261773..4894587e21 100644
--- a/files/templates/default.html
+++ b/files/templates/default.html
@@ -7,7 +7,7 @@
{% if v %}
-
+
{% if v.agendaposter %}
-
+
{% endif %}
diff --git a/files/templates/header.html b/files/templates/header.html
index 038f4ee7fe..200e2fcf38 100644
--- a/files/templates/header.html
+++ b/files/templates/header.html
@@ -40,8 +40,16 @@
{% if sub %}
/h/{{sub.name}}
{% elif SITE_NAME == 'rDrama' %}
+
-
+
{% endif %}
diff --git a/files/templates/log.html b/files/templates/log.html
index 649b006d20..bc6580e4a2 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 8c0b1a7799..ad85d11687 100644
--- a/files/templates/login.html
+++ b/files/templates/login.html
@@ -18,7 +18,7 @@
{% endblock %}
-
+
diff --git a/files/templates/login_2fa.html b/files/templates/login_2fa.html
index b0b81191b2..3d4cb6eeed 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 02f88eb351..1077be5de0 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/sidebar_rDrama.html b/files/templates/sidebar_rDrama.html
index b88bc4e6eb..3d21a0300f 100644
--- a/files/templates/sidebar_rDrama.html
+++ b/files/templates/sidebar_rDrama.html
@@ -28,7 +28,7 @@
{% endif %}
- {% if v.id in (AEVANN_ID,CARP_ID) %}
+ {% if v.admin_level > 2 %}
CREATE HOLE
{% endif %}
{% if v.mods(sub.name) %}
@@ -40,7 +40,7 @@
HOLE EXILEES
HOLE BLOCKERS
{% else %}
- {% if v and v.id in (AEVANN_ID,CARP_ID) %}
+ {% if v and v.admin_level > 2 %}
CREATE HOLE
{% endif %}
EMOJI MEGATHREAD
diff --git a/files/templates/sign_up.html b/files/templates/sign_up.html
index f0e80bc432..0c8f9d06a2 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 7a07dd1230..ab508a2917 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 %}
-
+