diff --git a/src/index.py b/src/index.py index ac0c3db..7a5da66 100644 --- a/src/index.py +++ b/src/index.py @@ -1,13 +1,13 @@ import datetime, os, re from bottle import error, response, route, run, static_file, template, TEMPLATE_PATH -# List up to 3 recommended articles for current article def list_rec(page): loc = 'diary/entries/' result = [] rec = [] comment = "" if isinstance(page, int): + # Collect recommended articles from comment line with open('diary/entries/' + str(page)) as f: comment = f.readline() comment = comment.replace('