Add trailing final newlines to source files.
Touched a ton of files to finally standardize on having trailing final newlines, as best practice recommends and so our devs stop accidentally fighting each other over it. This was performed automatically with the following: git ls-files -z '*.py' | while IFS= read -rd '' f; \ do tail -c1 < "$f" | read -r _ || echo >> "$f"; done git ls-files -z '*.css' | while IFS= read -rd '' f; \ do tail -c1 < "$f" | read -r _ || echo >> "$f"; doneremotes/1693176582716663532/tmp_refs/heads/watchparty
parent
11a9efb7cb
commit
4a54c6219a
|
@ -0,0 +1 @@
|
|||
|
|
@ -137,4 +137,4 @@ elif "load_chat" in argv:
|
|||
else:
|
||||
from files.routes import *
|
||||
|
||||
stdout.flush()
|
||||
stdout.flush()
|
||||
|
|
|
@ -154,4 +154,4 @@ blockquote a {
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #949494 !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -87,4 +87,4 @@
|
|||
51% {transform: translate(105vw,-86vh) rotate(180deg);}
|
||||
100% {transform: translate(-70vw,-86vh) rotate(180deg);}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -106,4 +106,4 @@ blockquote {
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #949494 !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -94,4 +94,4 @@ pre {
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #7a7a7a !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -145,4 +145,4 @@ color: var(--gray-700);
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #6e6e6e !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -82,4 +82,4 @@ blockquote {
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #7a7a7a !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -6283,4 +6283,4 @@ div.markdown {
|
|||
|
||||
.bug {
|
||||
pointer-events: none !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -63,4 +63,4 @@ body, .navbar-light, .navbar-dark, .card, .modal-content, .comment-write textare
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #6e6e6e !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -78,4 +78,4 @@ pre {
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #7a7a7a !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -232,4 +232,4 @@
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #b0b0b0 !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -168,4 +168,4 @@ blockquote {
|
|||
|
||||
h5.post-title a:visited {
|
||||
color: #5c5c5c !important;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -25,4 +25,4 @@ from .casino_game import *
|
|||
from .hats import *
|
||||
from .marsey import *
|
||||
from .transactions import *
|
||||
from .streamers import *
|
||||
from .streamers import *
|
||||
|
|
|
@ -76,4 +76,4 @@ class ClientAuth(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<ClientAuth(user_id={self.user_id}, oauth_client={self.oauth_client})>"
|
||||
return f"<ClientAuth(user_id={self.user_id}, oauth_client={self.oauth_client})>"
|
||||
|
|
|
@ -447,4 +447,4 @@ class Comment(Base):
|
|||
body += f"<strong class='ml-2'>Lost. The answer was: {wordle_answer}</strong>"
|
||||
|
||||
body += '</span>'
|
||||
return body
|
||||
return body
|
||||
|
|
|
@ -14,4 +14,4 @@ class BannedDomain(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<BannedDomain(domain={self.domain})>"
|
||||
return f"<BannedDomain(domain={self.domain})>"
|
||||
|
|
|
@ -18,4 +18,4 @@ class Exile(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Exile(user_id={self.user_id}, sub={self.sub})>"
|
||||
return f"<Exile(user_id={self.user_id}, sub={self.sub})>"
|
||||
|
|
|
@ -49,4 +49,4 @@ class CommentFlag(Base):
|
|||
|
||||
@lazy
|
||||
def realreason(self, v):
|
||||
return censor_slurs(self.reason, v)
|
||||
return censor_slurs(self.reason, v)
|
||||
|
|
|
@ -17,4 +17,4 @@ class Follow(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Follow(id={self.id})>"
|
||||
return f"<Follow(id={self.id})>"
|
||||
|
|
|
@ -61,4 +61,4 @@ class Hat(Base):
|
|||
|
||||
@lazy
|
||||
def censored_description(self, v):
|
||||
return self.hat_def.censored_description(v)
|
||||
return self.hat_def.censored_description(v)
|
||||
|
|
|
@ -17,4 +17,4 @@ class Marsey(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Marsey(name={self.name})>"
|
||||
return f"<Marsey(name={self.name})>"
|
||||
|
|
|
@ -16,4 +16,4 @@ class Mod(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Mod(user_id={self.user_id}, sub={self.sub})>"
|
||||
return f"<Mod(user_id={self.user_id}, sub={self.sub})>"
|
||||
|
|
|
@ -448,4 +448,4 @@ ACTIONTYPES = {
|
|||
|
||||
ACTIONTYPES2 = deepcopy(ACTIONTYPES)
|
||||
ACTIONTYPES2.pop("shadowban")
|
||||
ACTIONTYPES2.pop("unshadowban")
|
||||
ACTIONTYPES2.pop("unshadowban")
|
||||
|
|
|
@ -20,4 +20,4 @@ class Notification(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Notification(id={self.id})>"
|
||||
return f"<Notification(id={self.id})>"
|
||||
|
|
|
@ -101,4 +101,4 @@ class CommentOptionVote(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<CommentOptionVote(option_id={self.option_id}, user_id={self.user_id})>"
|
||||
return f"<CommentOptionVote(option_id={self.option_id}, user_id={self.user_id})>"
|
||||
|
|
|
@ -36,4 +36,4 @@ class CommentSaveRelationship(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<CommentSaveRelationship(user_id={self.user_id}, comment_id={self.comment_id})>"
|
||||
return f"<CommentSaveRelationship(user_id={self.user_id}, comment_id={self.comment_id})>"
|
||||
|
|
|
@ -10,4 +10,4 @@ if SITE == 'pcmemes.net':
|
|||
id = Column(String, primary_key=True)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Streamer(id={self.id})>"
|
||||
return f"<Streamer(id={self.id})>"
|
||||
|
|
|
@ -65,4 +65,4 @@ class Sub(Base):
|
|||
@property
|
||||
@lazy
|
||||
def follow_num(self):
|
||||
return len(self.followers)
|
||||
return len(self.followers)
|
||||
|
|
|
@ -13,4 +13,4 @@ class SubBlock(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<SubBlock(user_id={self.user_id}, sub={self.sub})>"
|
||||
return f"<SubBlock(user_id={self.user_id}, sub={self.sub})>"
|
||||
|
|
|
@ -13,4 +13,4 @@ class SubJoin(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<SubJoin(user_id={self.user_id}, sub={self.sub})>"
|
||||
return f"<SubJoin(user_id={self.user_id}, sub={self.sub})>"
|
||||
|
|
|
@ -13,4 +13,4 @@ class SubSubscription(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<SubSubscription(user_id={self.user_id}, sub={self.sub})>"
|
||||
return f"<SubSubscription(user_id={self.user_id}, sub={self.sub})>"
|
||||
|
|
|
@ -459,4 +459,4 @@ class Submission(Base):
|
|||
|
||||
@lazy
|
||||
def active_flags(self, v):
|
||||
return len(self.filtered_flags(v))
|
||||
return len(self.filtered_flags(v))
|
||||
|
|
|
@ -17,4 +17,4 @@ class Subscription(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Subscription(id={self.id})>"
|
||||
return f"<Subscription(id={self.id})>"
|
||||
|
|
|
@ -15,4 +15,4 @@ if KOFI_TOKEN:
|
|||
claimed = Column(Boolean)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<Transaction(id={self.id})>"
|
||||
return f"<Transaction(id={self.id})>"
|
||||
|
|
|
@ -948,4 +948,4 @@ class User(Base):
|
|||
if v and (v.sigs_disabled or v.poor):
|
||||
return False
|
||||
|
||||
return True
|
||||
return True
|
||||
|
|
|
@ -18,4 +18,4 @@ class UserBlock(Base):
|
|||
super().__init__(*args, **kwargs)
|
||||
|
||||
def __repr__(self):
|
||||
return f"<UserBlock(user={self.user_id}, target={self.target_id})>"
|
||||
return f"<UserBlock(user={self.user_id}, target={self.target_id})>"
|
||||
|
|
|
@ -63,4 +63,4 @@ class CommentVote(Base):
|
|||
"vote_type":self.vote_type,
|
||||
"user":self.user.json,
|
||||
"comment":self.comment.json
|
||||
}
|
||||
}
|
||||
|
|
|
@ -129,4 +129,4 @@ if PUSHER_ID != 'blahblahblah':
|
|||
}
|
||||
},
|
||||
)
|
||||
stdout.flush()
|
||||
stdout.flush()
|
||||
|
|
|
@ -1098,4 +1098,4 @@ forced_hats = {
|
|||
"marsify": ("Marsified", "I can't pick my own Marseys, help!"),
|
||||
"is_suspended": ("Behind Bars", "This user is banned and needs to do better!"),
|
||||
"agendaposter": ("Egg_irl", "This user is getting in touch with xir identity!")
|
||||
}
|
||||
}
|
||||
|
|
|
@ -154,4 +154,4 @@ def give_monthly_marseybux_task_kofi():
|
|||
)
|
||||
g.db.add(ma)
|
||||
|
||||
return True
|
||||
return True
|
||||
|
|
|
@ -51,4 +51,4 @@ def send_changelog_message(message):
|
|||
|
||||
def send_wpd_message(message):
|
||||
data={"content": message}
|
||||
requests.post("https://discordapp.com/api/channels/1013990963846332456/messages", headers=headers, data=data, timeout=5)
|
||||
requests.post("https://discordapp.com/api/channels/1013990963846332456/messages", headers=headers, data=data, timeout=5)
|
||||
|
|
|
@ -9,4 +9,4 @@ def marsify(text):
|
|||
if len(x) > 3 and x in marsey_mappings:
|
||||
marsey = choice(marsey_mappings[x])
|
||||
new_text += f':{marsey}: '
|
||||
return new_text
|
||||
return new_text
|
||||
|
|
|
@ -135,4 +135,4 @@ def process_image(filename=None, resize=0, trim=False):
|
|||
os.remove(filename)
|
||||
abort(417)
|
||||
|
||||
return filename
|
||||
return filename
|
||||
|
|
|
@ -89,4 +89,4 @@ def notify_mentions(send_to, mentions, mention_str='site mention'):
|
|||
|
||||
for user_id in send_to:
|
||||
notif = Notification(comment_id=new_comment.id, user_id=user_id)
|
||||
g.db.add(notif)
|
||||
g.db.add(notif)
|
||||
|
|
|
@ -47,4 +47,4 @@ def sort_posts(sort, posts):
|
|||
elif sort == "comments":
|
||||
return posts.order_by(Submission.comment_count.desc(), Submission.created_utc.desc())
|
||||
else:
|
||||
return posts.order_by(Submission.downvotes - Submission.upvotes, Submission.created_utc.desc())
|
||||
return posts.order_by(Submission.downvotes - Submission.upvotes, Submission.created_utc.desc())
|
||||
|
|
|
@ -43,4 +43,4 @@ def check_for_treasure(in_text, from_comment):
|
|||
|
||||
|
||||
user.coins += amount
|
||||
from_comment.treasure_amount = str(amount)
|
||||
from_comment.treasure_amount = str(amount)
|
||||
|
|
|
@ -21,4 +21,4 @@ from .casino import *
|
|||
from .polls import *
|
||||
from .notifications import *
|
||||
from .hats import *
|
||||
from .asset_submissions import *
|
||||
from .asset_submissions import *
|
||||
|
|
|
@ -472,4 +472,4 @@ def update_hat(v):
|
|||
)
|
||||
g.db.add(ma)
|
||||
|
||||
return render_template("update_assets.html", v=v, msg=f"'{name}' updated successfully!", type="Hat")
|
||||
return render_template("update_assets.html", v=v, msg=f"'{name}' updated successfully!", type="Hat")
|
||||
|
|
|
@ -127,4 +127,4 @@ def discord_redirect(v):
|
|||
requests.patch(url, headers=headers, json=data, timeout=5)
|
||||
|
||||
|
||||
return redirect(f"https://discord.com/channels/{DISCORD_SERVER_ID}/{DISCORD_WELCOME_CHANNEL}")
|
||||
return redirect(f"https://discord.com/channels/{DISCORD_SERVER_ID}/{DISCORD_WELCOME_CHANNEL}")
|
||||
|
|
|
@ -93,4 +93,4 @@ def allow_nsfw():
|
|||
session["over_18"] = int(time.time()) + 3600
|
||||
redir = request.values.get("redir")
|
||||
if is_site_url(redir): return redirect(redir)
|
||||
return redirect('/')
|
||||
return redirect('/')
|
||||
|
|
|
@ -259,4 +259,4 @@ def comment_idlist(page=1, v=None, nsfw=False, sort="new", t="all", gt=0, lt=0,
|
|||
comments = sort_comments(sort, comments)
|
||||
|
||||
comments = comments.offset(25 * (page - 1)).limit(26).all()
|
||||
return [x[0] for x in comments]
|
||||
return [x[0] for x in comments]
|
||||
|
|
|
@ -135,4 +135,4 @@ def hat_owners(v, hat_id):
|
|||
users=users,
|
||||
next_exists=next_exists,
|
||||
page=page,
|
||||
)
|
||||
)
|
||||
|
|
|
@ -310,4 +310,4 @@ def notifications(v):
|
|||
page=page,
|
||||
standalone=True,
|
||||
render_replies=True,
|
||||
)
|
||||
)
|
||||
|
|
|
@ -125,4 +125,4 @@ def option_votes_comment(option_id, v):
|
|||
return render_template("poll_votes.html",
|
||||
v=v,
|
||||
thing=option,
|
||||
ups=ups)
|
||||
ups=ups)
|
||||
|
|
|
@ -166,4 +166,4 @@ def remove_report_comment(v, cid, uid):
|
|||
g.db.add(ma)
|
||||
|
||||
|
||||
return {"message": "Report removed successfully!"}
|
||||
return {"message": "Report removed successfully!"}
|
||||
|
|
|
@ -1500,4 +1500,4 @@ def settings_kofi(v):
|
|||
|
||||
g.db.add(transaction)
|
||||
|
||||
return {"message": f"{patron} rewards claimed!"}
|
||||
return {"message": f"{patron} rewards claimed!"}
|
||||
|
|
|
@ -34,4 +34,4 @@ def test_signup():
|
|||
assert signup_post_response.status_code == 302
|
||||
assert "error" not in signup_post_response.location
|
||||
|
||||
# we should now be logged in and able to post
|
||||
# we should now be logged in and able to post
|
||||
|
|
Loading…
Reference in New Issue