forked from rDrama/rDrama
fsd
parent
c8efa3ade1
commit
94151bf2d6
|
@ -185,6 +185,8 @@ def award_post(pid, v):
|
||||||
elif author.unban_utc:
|
elif author.unban_utc:
|
||||||
author.unban_utc += 86400
|
author.unban_utc += 86400
|
||||||
send_repeatable_notification(author.id, f"Your account has been banned for **yet another day** for {link}. Seriously man?")
|
send_repeatable_notification(author.id, f"Your account has been banned for **yet another day** for {link}. Seriously man?")
|
||||||
|
if request.host == 'rdrama.net' and v.id == CARP_ID:
|
||||||
|
send_repeatable_notification(AEVANN_ID, link)
|
||||||
elif kind == "unban":
|
elif kind == "unban":
|
||||||
if not author.is_suspended or not author.unban_utc or time.time() > author.unban_utc: abort(403)
|
if not author.is_suspended or not author.unban_utc or time.time() > author.unban_utc: abort(403)
|
||||||
|
|
||||||
|
@ -202,6 +204,8 @@ def award_post(pid, v):
|
||||||
author.unban_utc = int(time.time()) + 30 * 86400
|
author.unban_utc = int(time.time()) + 30 * 86400
|
||||||
link = f"[this post]({post.shortlink})"
|
link = f"[this post]({post.shortlink})"
|
||||||
send_repeatable_notification(author.id, f"Your account has been banned permanently for {link}. You must [provide the admins](/contact) a timestamped picture of you touching grass/snow/sand/ass to get unbanned!")
|
send_repeatable_notification(author.id, f"Your account has been banned permanently for {link}. You must [provide the admins](/contact) a timestamped picture of you touching grass/snow/sand/ass to get unbanned!")
|
||||||
|
if request.host == 'rdrama.net' and v.id == CARP_ID:
|
||||||
|
send_repeatable_notification(AEVANN_ID, link)
|
||||||
elif kind == "pin":
|
elif kind == "pin":
|
||||||
if post.stickied and post.stickied_utc:
|
if post.stickied and post.stickied_utc:
|
||||||
post.stickied_utc += 3600
|
post.stickied_utc += 3600
|
||||||
|
@ -429,6 +433,9 @@ def award_comment(cid, v):
|
||||||
elif author.unban_utc:
|
elif author.unban_utc:
|
||||||
author.unban_utc += 86400
|
author.unban_utc += 86400
|
||||||
send_repeatable_notification(author.id, f"Your account has been banned for **yet another day** for {link}. Seriously man?")
|
send_repeatable_notification(author.id, f"Your account has been banned for **yet another day** for {link}. Seriously man?")
|
||||||
|
if request.host == 'rdrama.net' and v.id == CARP_ID:
|
||||||
|
send_repeatable_notification(AEVANN_ID, link)
|
||||||
|
|
||||||
elif kind == "unban":
|
elif kind == "unban":
|
||||||
if not author.is_suspended or not author.unban_utc or time.time() > author.unban_utc: abort(403)
|
if not author.is_suspended or not author.unban_utc or time.time() > author.unban_utc: abort(403)
|
||||||
|
|
||||||
|
@ -446,6 +453,8 @@ def award_comment(cid, v):
|
||||||
author.unban_utc = int(time.time()) + 30 * 86400
|
author.unban_utc = int(time.time()) + 30 * 86400
|
||||||
link = f"[this comment]({c.shortlink})"
|
link = f"[this comment]({c.shortlink})"
|
||||||
send_repeatable_notification(author.id, f"Your account has been banned permanently for {link}. You must [provide the admins](/contact) a timestamped picture of you touching grass/snow/sand/ass to get unbanned!")
|
send_repeatable_notification(author.id, f"Your account has been banned permanently for {link}. You must [provide the admins](/contact) a timestamped picture of you touching grass/snow/sand/ass to get unbanned!")
|
||||||
|
if request.host == 'rdrama.net' and v.id == CARP_ID:
|
||||||
|
send_repeatable_notification(AEVANN_ID, link)
|
||||||
elif kind == "pin":
|
elif kind == "pin":
|
||||||
if c.is_pinned and c.is_pinned_utc: c.is_pinned_utc += 3600
|
if c.is_pinned and c.is_pinned_utc: c.is_pinned_utc += 3600
|
||||||
else:
|
else:
|
||||||
|
|
|
@ -1366,6 +1366,9 @@ def submit_post(v, sub=None):
|
||||||
post.upvotes += 3
|
post.upvotes += 3
|
||||||
g.db.add(post)
|
g.db.add(post)
|
||||||
|
|
||||||
|
if request.host == 'rdrama.net' and v.id == CARP_ID:
|
||||||
|
send_repeatable_notification(AEVANN_ID, post.permalink)
|
||||||
|
|
||||||
g.db.commit()
|
g.db.commit()
|
||||||
|
|
||||||
cache.delete_memoized(frontlist)
|
cache.delete_memoized(frontlist)
|
||||||
|
|
|
@ -118,7 +118,6 @@
|
||||||
|
|
||||||
<label for="body" class="mt-3">Text<i class="fas fa-info-circle text-gray-400 ml-1" data-bs-toggle="tooltip" data-bs-placement="top" title="Uses markdown. Limited to 20000 characters."></i></label>
|
<label for="body" class="mt-3">Text<i class="fas fa-info-circle text-gray-400 ml-1" data-bs-toggle="tooltip" data-bs-placement="top" title="Uses markdown. Limited to 20000 characters."></i></label>
|
||||||
|
|
||||||
<div>
|
|
||||||
<textarea form="submitform" id="post-text" class="form-control rounded" aria-label="With textarea" placeholder="Optional if you have a link or an image." rows="7" name="body" oninput="markdown('post-text','preview');charLimit('post-text','character-count-submit-text-form');checkForRequired();savetext()" {% if v.longpost %}minlength="280"{% endif %} maxlength="{% if v.bird %}140{% else %}20000{% endif %}" required></textarea>
|
<textarea form="submitform" id="post-text" class="form-control rounded" aria-label="With textarea" placeholder="Optional if you have a link or an image." rows="7" name="body" oninput="markdown('post-text','preview');charLimit('post-text','character-count-submit-text-form');checkForRequired();savetext()" {% if v.longpost %}minlength="280"{% endif %} maxlength="{% if v.bird %}140{% else %}20000{% endif %}" required></textarea>
|
||||||
|
|
||||||
<div class="btn btn-secondary fl-r mt-3" onclick="document.getElementById('preview').classList.toggle('d-none');">
|
<div class="btn btn-secondary fl-r mt-3" onclick="document.getElementById('preview').classList.toggle('d-none');">
|
||||||
|
@ -127,8 +126,6 @@
|
||||||
|
|
||||||
<div class="text-small font-weight-bold mt-1" id="character-count-submit-text-form" style="right: 1rem; bottom: 0.5rem; z-index: 3;"></div>
|
<div class="text-small font-weight-bold mt-1" id="character-count-submit-text-form" style="right: 1rem; bottom: 0.5rem; z-index: 3;"></div>
|
||||||
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<p></p>
|
<p></p>
|
||||||
<small onclick="makeBold('post-text')" class="btn btn-secondary format d-inline-block m-0">
|
<small onclick="makeBold('post-text')" class="btn btn-secondary format d-inline-block m-0">
|
||||||
<i class="fas fa-bold" aria-hidden="true" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Bold"></i>
|
<i class="fas fa-bold" aria-hidden="true" data-bs-toggle="tooltip" data-bs-placement="bottom" title="Bold"></i>
|
||||||
|
@ -226,7 +223,7 @@
|
||||||
|
|
||||||
<script src="/assets/js/marked.js?v=256"></script>
|
<script src="/assets/js/marked.js?v=256"></script>
|
||||||
<script src="/assets/js/formatting.js?v=240"></script>
|
<script src="/assets/js/formatting.js?v=240"></script>
|
||||||
<script src="/assets/js/submit.js?v=255"></script>
|
<script src="/assets/js/submit.js?v=256"></script>
|
||||||
{% include "emoji_modal.html" %}
|
{% include "emoji_modal.html" %}
|
||||||
{% include "gif_modal.html" %}
|
{% include "gif_modal.html" %}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue