forked from MarseyWorld/MarseyWorld
fix filtering in notificaitons/userpages
parent
6cb6d54d91
commit
5a2afff7bb
|
@ -228,7 +228,6 @@ def post_id(pid, anything=None, v=None):
|
|||
def edit_post(pid, v):
|
||||
|
||||
title = request.form.get("title")
|
||||
if "<" in title: return {"error": f"Titles can't contain <"}
|
||||
|
||||
p = get_post(pid)
|
||||
|
||||
|
@ -522,9 +521,6 @@ def submit_post(v):
|
|||
title = request.form.get("title", "")
|
||||
url = request.form.get("url", "")
|
||||
|
||||
if "<" in title:
|
||||
return render_template("submit.html", v=v, error="Titles can't contain <", title=title[:500], url=url, body=request.form.get("body", "")), 400
|
||||
|
||||
if url:
|
||||
repost = g.db.query(Submission).join(Submission.submission_aux).filter(
|
||||
SubmissionAux.url.ilike(url),
|
||||
|
|
|
@ -677,11 +677,6 @@ def settings_title_change(v):
|
|||
|
||||
new_name=request.form.get("title").strip()[:100]
|
||||
|
||||
if "<" in new_name:
|
||||
return render_template("settings_profile.html",
|
||||
v=v,
|
||||
error=f"Flairs can't contain <")
|
||||
|
||||
#make sure name is different
|
||||
if new_name==v.customtitle:
|
||||
return render_template("settings_profile.html",
|
||||
|
|
|
@ -82,15 +82,15 @@
|
|||
<span class="align-top">
|
||||
{% if c.parent_submission %}
|
||||
{% if c.author_id==v.id and c.child_comments and is_notification_page%}
|
||||
<span class="font-weight-bold">Comment {{'Replies' if (c.child_comments | length)>1 else 'Reply'}}: <a href="{{c.post.permalink}}">{{c.post.title | safe}}</a></span>
|
||||
<span class="font-weight-bold">Comment {{'Replies' if (c.child_comments | length)>1 else 'Reply'}}: <a href="{{c.post.permalink}}">{{c.post.realtitle(v) | safe}}</a></span>
|
||||
{% elif c.post.author_id==v.id and c.level == 1 and is_notification_page%}
|
||||
<span class="font-weight-bold">Post Reply: <a href="{{c.post.permalink}}">{{c.post.title | safe}}</a></span>
|
||||
<span class="font-weight-bold">Post Reply: <a href="{{c.post.permalink}}">{{c.post.realtitle(v) | safe}}</a></span>
|
||||
{% elif is_notification_page and c.parent_submission in v.subscribed_idlist() %}
|
||||
<span class="font-weight-bold">Subscribed Thread: <a href="{{c.post.permalink}}">{{c.post.title | safe}}</a></span>
|
||||
<span class="font-weight-bold">Subscribed Thread: <a href="{{c.post.permalink}}">{{c.post.realtitle(v) | safe}}</a></span>
|
||||
{% elif is_notification_page %}
|
||||
<span class="font-weight-bold">Username Mention: <a href="{{c.post.permalink}}">{{c.post.title | safe}}</a></span>
|
||||
<span class="font-weight-bold">Username Mention: <a href="{{c.post.permalink}}">{{c.post.realtitle(v) | safe}}</a></span>
|
||||
{% else %}
|
||||
<span class="font-weight-bold"><a href="{{c.post.permalink}}">{{c.post.title | safe}}</a></span>
|
||||
<span class="font-weight-bold"><a href="{{c.post.permalink}}">{{c.post.realtitle(v) | safe}}</a></span>
|
||||
{% endif %}
|
||||
{% elif c.author_id==1046 or c.author_id==2360 %}
|
||||
<span class="font-weight-bold">{{'SITE_NAME' | app_config}} Notification</span>
|
||||
|
@ -511,4 +511,4 @@
|
|||
|
||||
|
||||
</pre>
|
||||
</body>
|
||||
</body>
|
||||
|
|
|
@ -52,7 +52,7 @@
|
|||
{% endif %}
|
||||
|
||||
{% else %}
|
||||
<title>{{p.title | safe}} - {{'SITE_NAME' | app_config}}</title>
|
||||
<title>{{p.title}} - {{'SITE_NAME' | app_config}}</title>
|
||||
|
||||
|
||||
<meta property="og:article:author" content="{{'@'+p.author.username}}" />
|
||||
|
@ -634,4 +634,4 @@
|
|||
{% include "gif_modal.html" %}
|
||||
{% include "emoji_modal.html" %}
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
{% endblock %}
|
||||
|
|
|
@ -1 +1 @@
|
|||
INSERT INTO public.badge_defs VALUES (6, 'Beta User', 'Joined during open beta', 'beta.png', 4, 3, NULL);
|
||||
INSERT INTO public.badge_defs VALUES (6, 'Beta User', 'Joined during open beta', 'beta.png', 3, NULL);
|
||||
|
|
Loading…
Reference in New Issue