Doc posts

This commit is contained in:
Peppuz 2018-04-24 18:20:47 +02:00
parent a32f16e07e
commit df55fe032c

View File

@ -58,5 +58,8 @@ POST_DIR = "."
@api.route("/posts") @api.route("/posts")
def posts_list(): def posts_list():
"""
Returns all .md files under POST_DIR
"""
posts = glob(f"{POST_DIR}/**/*.md", recursive=True) posts = glob(f"{POST_DIR}/**/*.md", recursive=True)
return jsonify(posts) return jsonify(posts)