various rendering changes
This commit is contained in:
1 parent
d22af9734e
commit
092759e4b1
5 files changed
+14
-5
No files matched your search
+3
-2
@@ -3,6 +3,7 @@ import configparser
|
||||
import random
|
||||
|
||||
import flask
|
||||
import markdown
|
||||
|
||||
from post import Post
|
||||
|
||||
@@ -43,12 +44,12 @@ def get_posts(category_filter : str | None = None) -> list[Post]:
|
||||
return reversed(ordered_posts)
|
||||
|
||||
def get_status() -> str:
|
||||
with open(STATUS_FILE, 'r') as file:
|
||||
with open(STATUS_FILE, 'r', encoding='utf-8') as file:
|
||||
statuses = file.readlines()
|
||||
|
||||
status = random.randint(0, len(statuses) - 1)
|
||||
|
||||
return statuses[status]
|
||||
return markdown.markdown(statuses[status])
|
||||
|
||||
@app.route('/')
|
||||
def index():
|
||||
|
||||
Reference in new issue
Block a user