v
This commit is contained in:
parent
4ce6da758b
commit
d1c79b2305
7 changed files with 26 additions and 16 deletions
|
@ -33,6 +33,7 @@ function morecomments(cid) {
|
|||
});
|
||||
popovertrigger()
|
||||
}
|
||||
btn.disabled = false;
|
||||
}
|
||||
xhr.send(form)
|
||||
}
|
||||
|
|
|
@ -140,8 +140,8 @@ function post_reply(id){
|
|||
}
|
||||
catch(e) {console.log(e)}
|
||||
new bootstrap.Toast(document.getElementById('toast-post-error')).show();
|
||||
btn.classList.remove('disabled');
|
||||
}
|
||||
btn.classList.remove('disabled');
|
||||
}
|
||||
xhr.send(form)
|
||||
}
|
||||
|
@ -173,8 +173,8 @@ function comment_edit(id){
|
|||
}
|
||||
catch(e) {console.log(e)}
|
||||
new bootstrap.Toast(document.getElementById('toast-post-error')).show();
|
||||
btn.classList.remove('disabled');
|
||||
}
|
||||
btn.classList.remove('disabled');
|
||||
}
|
||||
xhr.send(form)
|
||||
}
|
||||
|
@ -207,8 +207,8 @@ function post_comment(fullname){
|
|||
}
|
||||
catch(e) {console.log(e)}
|
||||
new bootstrap.Toast(document.getElementById('toast-post-error')).show();
|
||||
btn.classList.remove('disabled');
|
||||
}
|
||||
btn.classList.remove('disabled');
|
||||
}
|
||||
xhr.send(form)
|
||||
}
|
||||
|
|
|
@ -17,6 +17,7 @@ function report_postModal(id) {
|
|||
xhr.onload=function() {
|
||||
document.getElementById("reportPostFormBefore").classList.add('d-none');
|
||||
document.getElementById("reportPostFormAfter").classList.remove('d-none');
|
||||
this.disabled = false;
|
||||
};
|
||||
|
||||
xhr.onerror=function(){alert(errortext)};
|
||||
|
|
|
@ -317,7 +317,8 @@ def api_comment(v):
|
|||
is_bot=is_bot,
|
||||
app_id=v.client.application.id if v.client else None,
|
||||
body_html=body_html,
|
||||
body=body[:10000]
|
||||
body=body[:10000],
|
||||
ghost=parent_post.ghost
|
||||
)
|
||||
|
||||
c.upvotes = 1
|
||||
|
@ -340,7 +341,7 @@ def api_comment(v):
|
|||
if request.host == 'pcmemes.net' and c.body.lower().startswith("based"):
|
||||
pill = re.match("based and (.{1,20}?)(-| )pilled", body, re.IGNORECASE)
|
||||
|
||||
if level == 1: basedguy = get_account(c.post.author_id)
|
||||
if level == 1: basedguy = get_account(parent_post.author_id)
|
||||
else: basedguy = get_account(c.parent_comment.author_id)
|
||||
basedguy.basedcount += 1
|
||||
if pill:
|
||||
|
@ -360,7 +361,8 @@ def api_comment(v):
|
|||
level=level+1,
|
||||
is_bot=True,
|
||||
body_html=body_based_html,
|
||||
top_comment_id=c.top_comment_id
|
||||
top_comment_id=c.top_comment_id,
|
||||
ghost=parent_post.ghost
|
||||
)
|
||||
|
||||
g.db.add(c_based)
|
||||
|
@ -390,7 +392,8 @@ def api_comment(v):
|
|||
level=level+1,
|
||||
is_bot=True,
|
||||
body_html=body_jannied_html,
|
||||
top_comment_id=c.top_comment_id
|
||||
top_comment_id=c.top_comment_id,
|
||||
ghost=parent_post.ghost
|
||||
)
|
||||
|
||||
g.db.add(c_jannied)
|
||||
|
@ -411,7 +414,8 @@ def api_comment(v):
|
|||
level=level+1,
|
||||
is_bot=True,
|
||||
body_html=body_html2,
|
||||
top_comment_id=c.top_comment_id
|
||||
top_comment_id=c.top_comment_id,
|
||||
ghost=parent_post.ghost
|
||||
)
|
||||
|
||||
g.db.add(c2)
|
||||
|
@ -446,7 +450,8 @@ def api_comment(v):
|
|||
level=level+1,
|
||||
is_bot=True,
|
||||
body_html=body_html2,
|
||||
top_comment_id=c.top_comment_id
|
||||
top_comment_id=c.top_comment_id,
|
||||
ghost=parent_post.ghost
|
||||
)
|
||||
|
||||
g.db.add(c2)
|
||||
|
@ -469,7 +474,8 @@ def api_comment(v):
|
|||
level=level+2,
|
||||
is_bot=True,
|
||||
body_html=body_html2,
|
||||
top_comment_id=c.top_comment_id
|
||||
top_comment_id=c.top_comment_id,
|
||||
ghost=parent_post.ghost
|
||||
)
|
||||
|
||||
g.db.add(c3)
|
||||
|
@ -485,7 +491,8 @@ def api_comment(v):
|
|||
level=level+3,
|
||||
is_bot=True,
|
||||
body_html=body_html2,
|
||||
top_comment_id=c.top_comment_id
|
||||
top_comment_id=c.top_comment_id,
|
||||
ghost=parent_post.ghost
|
||||
)
|
||||
|
||||
g.db.add(c4)
|
||||
|
@ -732,7 +739,8 @@ def edit_comment(cid, v):
|
|||
level=c.level+1,
|
||||
is_bot=True,
|
||||
body_html=body_jannied_html,
|
||||
top_comment_id=c.top_comment_id
|
||||
top_comment_id=c.top_comment_id,
|
||||
ghost=c.ghost
|
||||
)
|
||||
|
||||
g.db.add(c_jannied)
|
||||
|
|
|
@ -864,7 +864,7 @@
|
|||
|
||||
{% if v %}
|
||||
<script src="/static/assets/js/marked.js?a=220"></script>
|
||||
<script src="/static/assets/js/comments_v.js?a=233"></script>
|
||||
<script src="/static/assets/js/comments_v.js?a=234"></script>
|
||||
{% endif %}
|
||||
|
||||
<script src="/static/assets/js/clipboard.js?a=220"></script>
|
||||
|
@ -876,7 +876,7 @@
|
|||
{% include "expanded_image_modal.html" %}
|
||||
|
||||
<script src="/static/assets/js/comments+submission_listing.js?a=220"></script>
|
||||
<script src="/static/assets/js/comments.js?a=220"></script>
|
||||
<script src="/static/assets/js/comments.js?a=221"></script>
|
||||
|
||||
<script>
|
||||
{% if p and (not v or v.highlightcomments) %}
|
||||
|
|
|
@ -32,4 +32,4 @@
|
|||
</div>
|
||||
</div>
|
||||
|
||||
<script src="/static/assets/js/report_post_modal.js?a=220"></script>
|
||||
<script src="/static/assets/js/report_post_modal.js?a=221"></script>
|
|
@ -863,7 +863,7 @@
|
|||
</div>
|
||||
|
||||
{% if offset %}
|
||||
<script src="/static/assets/js/viewmore.js?a=220"></script>
|
||||
<script src="/static/assets/js/viewmore.js?a=221"></script>
|
||||
{% endif %}
|
||||
|
||||
{% elif not p.replies and p.deleted_utc == 0 %}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue