End individual post url in /

This commit is contained in:
PV Tejas 2026-03-11 20:27:06 +05:30
parent 13bdcaef9e
commit 89622db6c9
2 changed files with 4 additions and 3 deletions

View file

@ -86,9 +86,10 @@ def get_post(id, check_author=True):
return post
@bp.route('/<int:id>')
@bp.route('/<int:id>/')
def individual_post(id):
post = get_post(id, False)
post = dict(get_post(id, False))
post['body'] = markdown.markdown(post['body'])
return render_template('blog/post.html', post=post)
@bp.route('/<int:id>/update', methods=('GET', 'POST'))