remotes/1693045480750635534/spooky-22
Aevann1 2021-08-31 02:18:54 +02:00
parent 4e604adc2a
commit 2d013c0655
1 changed files with 0 additions and 3 deletions

View File

@ -233,9 +233,6 @@ def edit_post(pid, v):
if not p.author_id == v.id:
abort(403)
if p.is_banned:
abort(403)
body = request.form.get("body", "")
for i in re.finditer('^(https:\/\/.*\.(png|jpg|jpeg|gif|PNG|JPG|JPEG|GIF|9999))', body, re.MULTILINE): body = body.replace(i.group(1), f'![]({i.group(1)})')
with CustomRenderer() as renderer: body_md = renderer.render(mistletoe.Document(body))