remotes/1693045480750635534/spooky-22
Aevann1 2021-10-15 16:08:27 +02:00
parent 852778af6b
commit efa408ab2c
171 changed files with 28159 additions and 28269 deletions

0
.gitattributes vendored 100644 → 100755
View File

0
.gitignore vendored 100644 → 100755
View File

0
Dockerfile 100644 → 100755
View File

0
LICENSE 100644 → 100755
View File

0
appspec.yml 100644 → 100755
View File

0
buildspec.yml 100644 → 100755
View File

0
dependabot.yml 100644 → 100755
View File

0
disablesignups 100644 → 100755
View File

0
docker-compose.yml 100644 → 100755
View File

0
env 100644 → 100755
View File

0
files/__main__.py 100644 → 100755
View File

0
files/classes/__init__.py 100644 → 100755
View File

0
files/classes/alts.py 100644 → 100755
View File

10
files/classes/award.py 100644 → 100755
View File

@ -14,7 +14,7 @@ if site_name == "Drama":
"description": "Bans the author for a day.",
"icon": "fas fa-gavel",
"color": "text-danger",
"price": 5000
"price": 1500
},
"shit": {
"kind": "shit",
@ -22,7 +22,7 @@ if site_name == "Drama":
"description": "Makes flies swarm a post.",
"icon": "fas fa-poop",
"color": "text-black-50",
"price": 1000
"price": 500
},
"fireflies": {
"kind": "fireflies",
@ -30,7 +30,7 @@ if site_name == "Drama":
"description": "Puts stars on the post.",
"icon": "fas fa-sparkles",
"color": "text-warning",
"price": 1000
"price": 500
}
}
else:
@ -41,7 +41,7 @@ else:
"description": "Makes flies swarm a post.",
"icon": "fas fa-poop",
"color": "text-black-50",
"price": 1000
"price": 500
},
"fireflies": {
"kind": "fireflies",
@ -49,7 +49,7 @@ else:
"description": "Puts stars on the post.",
"icon": "fas fa-sparkles",
"color": "text-warning",
"price": 1000
"price": 500
}
}

1
files/classes/badges.py 100644 → 100755
View File

@ -83,7 +83,6 @@ class Badge(Base):
return {'text': self.text,
'name': self.name,
'created_utc': self.created_utc,
'url': self.url,
'icon_url':f"https://{app.config['SERVER_NAME']}{self.path}"
}

0
files/classes/clients.py 100644 → 100755
View File

0
files/classes/comment.py 100644 → 100755
View File

0
files/classes/domains.py 100644 → 100755
View File

0
files/classes/flags.py 100644 → 100755
View File

0
files/classes/mod_logs.py 100644 → 100755
View File

0
files/classes/submission.py 100644 → 100755
View File

0
files/classes/subscriptions.py 100644 → 100755
View File

10
files/classes/user.py 100644 → 100755
View File

@ -31,7 +31,7 @@ if site_name == "Drama":
"description": "Bans the author for a day.",
"icon": "fas fa-gavel",
"color": "text-danger",
"price": 5000
"price": 1500
},
"shit": {
"kind": "shit",
@ -39,7 +39,7 @@ if site_name == "Drama":
"description": "Makes flies swarm a post.",
"icon": "fas fa-poop",
"color": "text-black-50",
"price": 1000
"price": 500
},
"fireflies": {
"kind": "fireflies",
@ -47,7 +47,7 @@ if site_name == "Drama":
"description": "Puts stars on the post.",
"icon": "fas fa-sparkles",
"color": "text-warning",
"price": 1000
"price": 500
}
}
else:
@ -58,7 +58,7 @@ else:
"description": "Makes flies swarm a post.",
"icon": "fas fa-poop",
"color": "text-black-50",
"price": 1000
"price": 500
},
"fireflies": {
"kind": "fireflies",
@ -66,7 +66,7 @@ else:
"description": "Puts stars on the post.",
"icon": "fas fa-sparkles",
"color": "text-warning",
"price": 1000
"price": 500
}
}

0
files/classes/userblock.py 100644 → 100755
View File

0
files/classes/votes.py 100644 → 100755
View File

0
files/helpers/alerts.py 100644 → 100755
View File

121
files/helpers/const.py 100644 → 100755
View File

@ -130,126 +130,7 @@ SLURS = {
"LATINA ":"LATINX ",
"HISPANICS ":"LATINX ",
"HISPANIC ":"LATINX ",
"uss liberty incident":"tragic accident aboard the USS Liberty",
"USS Liberty Incident":"tragic accident aboard the USS Liberty",
"USS Liberty incident":"tragic accident aboard the USS Liberty",
"USS Liberty Incident":"tragic accident aboard the USS Liberty",
"uss Liberty incident":"tragic accident aboard the USS Liberty",
"uss liberty Incident":"tragic accident aboard the USS Liberty",
"USS LIBERTY INCIDENT":"TRAGIC ACCIDENT ABOARD THE USS LIBERTY",
"lavon affair":"Lavon Misunderstanding",
"Lavon affair":"Lavon Misunderstanding",
"Lavon Affair":"Lavon Misunderstanding",
"lavon Affair":"Lavon Misunderstanding",
"shylock":"Israeli friend",
"Shylock":"Israeli friend",
"SHYLOCK":"ISRAELI FRIEND",
"yid":"Israeli friend",
"Yid":"Israeli friend",
"YID":"ISRAELI FRIEND",
"heeb":"Israeli friend",
"Heeb":"Israeli friend",
"HEEB":"ISRAELI FRIEND",
"sheeny":"Israeli friend",
"Sheeny":"Israeli friend",
"SHEENY":"ISRAELI FRIEND",
"sheenies":"Israeli friends",
"Sheenies":"Israeli friends",
"SHEENIES":"ISRAELI FRIENDS",
"hymie":"Israeli friend",
"Hymie":"Israeli friend",
"HYMIES":"ISRAELI FRIENDS",
"allah":"Allah (SWT)",
"Allah":"Allah (SWT)",
"ALLAH":"ALLAH (SWT)",
"Mohammad":"Mohammad (PBUH)",
"Muhammad":"Mohammad (PBUH)",
"Mohammed":"Mohammad (PBUH)",
"Muhammed":"Mohammad (PBUH)",
"mohammad":"Mohammad (PBUH)",
"mohammed":"Mohammad (PBUH)",
"muhammad":"Mohammad (PBUH)",
"muhammed":"Mohammad (PBUH)",
"I HATE MARSEY":"I LOVE MARSEY",
"i hate marsey":"i love marsey",
"I hate Marsey":"I love Marsey",
"I hate marsey":"I love Marsey",
"libertarian":"pedophile",
"Libertarian":"Pedophile",
"LIBERTARIAN":"PEDOPHILE",
"Billie Eilish":"Billie Eilish (fat cow)",
"billie eilish":"bilie eilish (fat cow)",
"BILLIE EILISH":"BILIE EILISH (FAT COW)",
"dancing Israelis":"I love Israel",
"dancing israelis":"i love israel",
"DANCING ISRAELIS":"I LOVE ISRAEL",
"Dancing Israelis":"I love Israel",
"sodomite":"total dreamboat",
"Sodomite":"Total dreamboat",
"pajeet":"sexy Indian dude",
"Pajeet":"Sexy Indian dude",
"PAJEET":"SEXY INDIAN DUDE",
"female":"birthing person",
"Female":"Womb-haver",
"FEMALE":"birthing person",
"landlord":"landchad",
"Landlord":"Landchad",
"LANDLORD":"LANDCHAD",
"tenant":"renthog",
"Tenant":"Renthog",
"TENANT":"RENTHOG",
"renter":"rentoid",
"Renter":"Rentoid",
"RENTER":"RENTOID",
"autistic":"neurodivergent",
"Autistic":"Neurodivergent",
"AUTISTIC":"NEURODIVERGENT",
"anime":"p-dophilic japanese cartoons",
"Anime":"P-dophilic Japanese cartoons",
"ANIME":"P-DOPHILIC JAPANESE CARTOONS",
"holohoax":"I tried to claim the Holocaust didn't happen because I am a pencil-dicked imbecile and the word filter caught me lol",
"Holohoax":"I tried to claim the Holocaust didn't happen because I am a pencil-dicked imbecile and the word filter caught me lol",
"HOLOHOAX":"I tried to claim the Holocaust didn't happen because I am a pencil-dicked imbecile and the word filter caught me lol",
"groomercord":"discord (actually a pretty cool service)",
"Groomercord":"Discord (actually a pretty cool service)",
"GROOMERCORD":"DISCORD (ACTUALLY A PRETTY COOL SERVICE)",
"pedocord":"discord (actually a pretty cool service)",
"Pedocord":"Discord (actually a pretty cool service)",
"PEDOCORD":"DISCORD (ACTUALLY A PRETTY COOL SERVICE)",
"i hate carp":"i love carp",
"I hate carp":"I love carp",
"I HATE CARP":"I LOVE CARP",
"I hate Carp":"I love Carp",
"manlet":"little king",
"Manlet":"Little king",
"MANLET":"LITTLE KING",
"gamer":"g*mer",
"Gamer":"G*mer",
"GAMER":"G*MER",
"journalist":"journ*list",
"Journalist":"Journ*list",
"JOURNALIST":"JOURN*LIST",
"journalism":"journ*lism",
"Journalism":"Journ*lism",
"JOURNALISM":"JOURN*LISM",
"buttcheeks":"bulva",
"Buttcheeks":"Bulva",
"BUTTCHEEKS":"BULVA",
"asscheeks":"bulva",
"Asscheeks":"bulva",
"ASSCHEEKS":"BULVA",
"wuhan flu":"SARS-CoV-2 syndemic",
"Wuhan flu":"SARS-CoV-2 syndemic",
"Wuhan Flu":"SARS-CoV-2 syndemic",
"china flu":"SARS-CoV-2 syndemic",
"China flu":"SARS-CoV-2 syndemic",
"China Flu":"SARS-CoV-2 syndemic",
"china virus":"SARS-CoV-2 syndemic",
"China virus":"SARS-CoV-2 syndemic",
"China Virus":"SARS-CoV-2 syndemic",
"kung flu":"SARS-CoV-2 syndemic",
"Kung flu":"SARS-CoV-2 syndemic",
"Kung Flu":"SARS-CoV-2 syndemic",
" nig ":" 🏀 ",
" Nig ":" 🏀 ",
" NIG ":" 🏀 ",

0
files/helpers/discord.py 100644 → 100755
View File

0
files/helpers/filters.py 100644 → 100755
View File

0
files/helpers/get.py 100644 → 100755
View File

0
files/helpers/images.py 100644 → 100755
View File

0
files/helpers/jinja2.py 100644 → 100755
View File

0
files/helpers/lazy.py 100644 → 100755
View File

0
files/helpers/markdown.py 100644 → 100755
View File

8
files/helpers/sanitize.py 100644 → 100755
View File

@ -201,22 +201,22 @@ def sanitize(sanitized, noimages=False):
for i in re.finditer('" target="_blank">(https://youtube.com/watch\?v\=.*?)</a>', sanitized):
url = i.group(1)
replacing = f'<a href="{url}" rel="nofollow noopener noreferrer" target="_blank">{url}</a>'
htmlsource = f'<iframe class="embedvid" loading="lazy" data-src="{url}" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>'
htmlsource = f'<iframe class="embedvid" loading="lazy" src="/assets/images/loading.webp" data-src="{url}" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>'
sanitized = sanitized.replace(replacing, htmlsource.replace("watch?v=", "embed/"))
for i in re.finditer('<a href="(https://streamable.com/e/.*?)"', sanitized):
url = i.group(1)
replacing = f'<a href="{url}" rel="nofollow noopener noreferrer" target="_blank">{url}</a>'
htmlsource = f'<iframe class="embedvid" loading="lazy" data-src="{url}" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>'
htmlsource = f'<iframe class="embedvid" loading="lazy" src="/assets/images/loading.webp" data-src="{url}" frameborder="0" allow="accelerometer; autoplay; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>'
sanitized = sanitized.replace(replacing, htmlsource)
for i in re.finditer('<p>(https:.*?\.mp4)</p>', sanitized):
sanitized = sanitized.replace(i.group(0), f'<p><video controls loop preload="metadata" class="embedvid"><source data-src="{i.group(1)}" type="video/mp4"></video>')
sanitized = sanitized.replace(i.group(0), f'<p><video controls loop preload="metadata" class="embedvid"><source src="/assets/images/loading.webp" data-src="{i.group(1)}" type="video/mp4"></video>')
for i in re.finditer('<a href="(https://open.spotify.com/embed/.*?)"', sanitized):
url = i.group(1)
replacing = f'<a href="{url}" rel="nofollow noopener noreferrer" target="_blank">{url}</a>'
htmlsource = f'<iframe data-src="{url}" class="spotify" frameBorder="0" allowtransparency="true" allow="encrypted-media"></iframe>'
htmlsource = f'<iframe src="/assets/images/loading.webp" data-src="{url}" class="spotify" frameBorder="0" allowtransparency="true" allow="encrypted-media"></iframe>'
sanitized = sanitized.replace(replacing, htmlsource)
for rd in ["https://reddit.com/", "https://new.reddit.com/", "https://www.reddit.com/", "https://redd.it/"]:

0
files/helpers/security.py 100644 → 100755
View File

0
files/helpers/session.py 100644 → 100755
View File

0
files/helpers/sqla_values.py 100644 → 100755
View File

0
files/helpers/wrappers.py 100644 → 100755
View File

0
files/mail/__init__.py 100644 → 100755
View File

0
files/routes/__init__.py 100644 → 100755
View File

42
files/routes/admin.py 100644 → 100755
View File

@ -174,26 +174,26 @@ def monthly(v):
grant_awards = {}
if u.id == 1376:
grant_awards["fireflies"] = 100
grant_awards["fireflies"] = 40
grant_awards["ban"] = 10
elif u.patron == 1:
grant_awards["shit"] = 1
grant_awards["fireflies"] = 1
elif u.patron == 2:
grant_awards["shit"] = 2
grant_awards["fireflies"] = 2
elif u.patron == 2:
grant_awards["shit"] = 5
grant_awards["fireflies"] = 5
grant_awards["ban"] = 1
elif u.patron == 3:
grant_awards["shit"] = 10
grant_awards["fireflies"] = 10
grant_awards["shit"] = 5
grant_awards["fireflies"] = 5
grant_awards["ban"] = 2
elif u.patron == 4:
grant_awards["shit"] = 25
grant_awards["fireflies"] = 25
grant_awards["shit"] = 10
grant_awards["fireflies"] = 10
grant_awards["ban"] = 5
elif u.patron == 5 or u.patron == 8:
grant_awards["shit"] = 50
grant_awards["fireflies"] = 50
grant_awards["shit"] = 20
grant_awards["fireflies"] = 20
grant_awards["ban"] = 10
@ -416,27 +416,27 @@ def badge_grant_post(v):
if badge_id == 21:
if user.discord_id: add_role(user, "1")
grant_awards["shit"] = 2
grant_awards["fireflies"] = 2
grant_awards["shit"] = 1
grant_awards["fireflies"] = 1
elif badge_id == 22:
if user.discord_id: add_role(user, "2")
grant_awards["shit"] = 5
grant_awards["fireflies"] = 5
grant_awards["shit"] = 2
grant_awards["fireflies"] = 2
grant_awards["ban"] = 1
elif badge_id == 23:
if user.discord_id: add_role(user, "3")
grant_awards["shit"] = 10
grant_awards["fireflies"] = 10
grant_awards["shit"] = 5
grant_awards["fireflies"] = 5
grant_awards["ban"] = 2
elif badge_id in [24, 28]:
if user.discord_id: add_role(user, "4")
grant_awards["shit"] = 25
grant_awards["fireflies"] = 25
grant_awards["shit"] = 10
grant_awards["fireflies"] = 10
grant_awards["ban"] = 5
elif badge_id == 25:
if user.discord_id: add_role(user, "5")
grant_awards["shit"] = 50
grant_awards["fireflies"] = 50
grant_awards["shit"] = 20
grant_awards["fireflies"] = 20
grant_awards["ban"] = 10
if len(grant_awards):
@ -787,7 +787,7 @@ def admin_title_change(user_id, v):
if user.admin_level != 0: abort(403)
new_name=request.values.get("title").strip()
new_name=request.values.get("title").strip()[:256]
user.customtitleplain=new_name
new_name = sanitize(new_name)

20
files/routes/awards.py 100644 → 100755
View File

@ -18,7 +18,7 @@ def shop(v):
"description": "Bans the author for a day.",
"icon": "fas fa-gavel",
"color": "text-danger",
"price": 5000
"price": 1500
},
"shit": {
"kind": "shit",
@ -26,7 +26,7 @@ def shop(v):
"description": "Makes flies swarm a post.",
"icon": "fas fa-poop",
"color": "text-black-50",
"price": 1000
"price": 500
},
"fireflies": {
"kind": "fireflies",
@ -34,7 +34,7 @@ def shop(v):
"description": "Puts stars on the post.",
"icon": "fas fa-sparkles",
"color": "text-warning",
"price": 1000
"price": 500
}
}
else:
@ -45,7 +45,7 @@ def shop(v):
"description": "Makes flies swarm a post.",
"icon": "fas fa-poop",
"color": "text-black-50",
"price": 1000
"price": 500
},
"fireflies": {
"kind": "fireflies",
@ -53,7 +53,7 @@ def shop(v):
"description": "Puts stars on the post.",
"icon": "fas fa-sparkles",
"color": "text-warning",
"price": 1000
"price": 500
}
}
@ -95,7 +95,7 @@ def buy(v, award):
"description": "Bans the author for a day.",
"icon": "fas fa-gavel",
"color": "text-danger",
"price": 5000
"price": 1500
},
"shit": {
"kind": "shit",
@ -103,7 +103,7 @@ def buy(v, award):
"description": "Makes flies swarm a post.",
"icon": "fas fa-poop",
"color": "text-black-50",
"price": 1000
"price": 500
},
"fireflies": {
"kind": "fireflies",
@ -111,7 +111,7 @@ def buy(v, award):
"description": "Puts stars on the post.",
"icon": "fas fa-sparkles",
"color": "text-warning",
"price": 1000
"price": 500
}
}
else:
@ -122,7 +122,7 @@ def buy(v, award):
"description": "Makes flies swarm a post.",
"icon": "fas fa-poop",
"color": "text-black-50",
"price": 1000
"price": 500
},
"fireflies": {
"kind": "fireflies",
@ -130,7 +130,7 @@ def buy(v, award):
"description": "Puts stars on the post.",
"icon": "fas fa-sparkles",
"color": "text-warning",
"price": 1000
"price": 500
}
}

0
files/routes/comments.py 100644 → 100755
View File

0
files/routes/discord.py 100644 → 100755
View File

0
files/routes/errors.py 100644 → 100755
View File

0
files/routes/feeds.py 100644 → 100755
View File

0
files/routes/front.py 100644 → 100755
View File

0
files/routes/giphy.py 100644 → 100755
View File

0
files/routes/login.py 100644 → 100755
View File

0
files/routes/oauth.py 100644 → 100755
View File

0
files/routes/posts.py 100644 → 100755
View File

0
files/routes/reporting.py 100644 → 100755
View File

0
files/routes/search.py 100644 → 100755
View File

20
files/routes/settings.py 100644 → 100755
View File

@ -310,27 +310,27 @@ def gumroad(v):
grant_awards = {}
if tier == 1:
if v.discord_id: add_role(v, "1")
grant_awards["shit"] = 2
grant_awards["fireflies"] = 2
grant_awards["shit"] = 1
grant_awards["fireflies"] = 1
elif tier == 2:
if v.discord_id: add_role(v, "2")
grant_awards["shit"] = 5
grant_awards["fireflies"] = 5
grant_awards["shit"] = 2
grant_awards["fireflies"] = 2
grant_awards["ban"] = 1
elif tier == 3:
if v.discord_id: add_role(v, "3")
grant_awards["shit"] = 10
grant_awards["fireflies"] = 10
grant_awards["shit"] = 5
grant_awards["fireflies"] = 5
grant_awards["ban"] = 2
elif tier == 4:
if v.discord_id: add_role(v, "4")
grant_awards["shit"] = 25
grant_awards["fireflies"] = 25
grant_awards["shit"] = 10
grant_awards["fireflies"] = 10
grant_awards["ban"] = 5
elif tier == 5 or tier == 8:
if v.discord_id: add_role(v, "5")
grant_awards["shit"] = 50
grant_awards["fireflies"] = 50
grant_awards["shit"] = 20
grant_awards["fireflies"] = 20
grant_awards["ban"] = 10
thing = g.db.query(AwardRelationship).order_by(AwardRelationship.id.desc()).first().id

0
files/routes/static.py 100644 → 100755
View File

0
files/routes/users.py 100644 → 100755
View File

0
files/routes/votes.py 100644 → 100755
View File

View File

View File

0
files/templates/admin/app.html 100644 → 100755
View File

0
files/templates/admin/apps.html 100644 → 100755
View File

View File

View File

View File

View File

View File

View File

View File

View File

0
files/templates/admin/rules.html 100644 → 100755
View File

View File

0
files/templates/admins.html 100644 → 100755
View File

2
files/templates/api.html 100644 → 100755
View File

@ -6,7 +6,7 @@
{% endblock %}
{% block content %}
<img class="in-comment-image rounded-sm my-2" data-src="https://media.giphy.com/media/c6Wwc9cT05vMdhyTcM/giphy.webp" loading="lazy" height="100px" rel="nofollow noopener noreferrer" data-placeholder-background="red" style="max-height: 100px; max-width: 100%;">
<img class="in-comment-image rounded-sm my-2" src="/assets/images/loading.webp" data-src="https://media.giphy.com/media/c6Wwc9cT05vMdhyTcM/giphy.webp" loading="lazy" height="100px" rel="nofollow noopener noreferrer" data-placeholder-background="red" style="max-height: 100px; max-width: 100%;">
<pre>

0
files/templates/authforms.html 100644 → 100755
View File

0
files/templates/award_modal.html 100644 → 100755
View File

6
files/templates/badges.html 100644 → 100755
View File

@ -22,7 +22,7 @@
{% for badge in badges if badge.kind==1 %}
<tr>
<td>{{badge.name}}</td>
<td><img loading="lazy" src="{{badge.path}}" style="width:50px;height:50px">
<td><img loading="lazy" src="{{badge.path}}" width=50 height=50>
<td>{{badge.description}}</td>
</tr>
{% endfor %}
@ -43,7 +43,7 @@
{% for badge in badges if badge.kind==3 %}
<tr>
<td>{{badge.name}}</td>
<td><img loading="lazy" src="{{badge.path}}" style="width:50px;height:50px">
<td><img loading="lazy" src="{{badge.path}}" width=50 height=50>
<td>{{badge.description}}</td>
</tr>
{% endfor %}
@ -63,7 +63,7 @@
{% for badge in badges if badge.kind==4 %}
<tr>
<td>{{badge.name}}</td>
<td><img loading="lazy" src="{{badge.path}}" style="width:50px;height:50px">
<td><img loading="lazy" src="{{badge.path}}" width=50 height=50>
<td>{{badge.description}}</td>
</tr>
{% endfor %}

0
files/templates/ban_modal.html 100644 → 100755
View File

0
files/templates/banned.html 100644 → 100755
View File

0
files/templates/blocks.html 100644 → 100755
View File

0
files/templates/changelog.html 100644 → 100755
View File

View File

0
files/templates/comments.html 100644 → 100755
View File

0
files/templates/contact.html 100644 → 100755
View File

0
files/templates/default.html 100644 → 100755
View File

View File

View File

View File

View File

View File

View File

View File

View File

View File

0
files/templates/emoji_modal.html 100644 → 100755
View File

0
files/templates/errors/400.html 100644 → 100755
View File

0
files/templates/errors/401.html 100644 → 100755
View File

0
files/templates/errors/403.html 100644 → 100755
View File

0
files/templates/errors/404.html 100644 → 100755
View File

0
files/templates/errors/405.html 100644 → 100755
View File

Some files were not shown because too many files have changed in this diff Show More