From ee6f1405d4ef2f0af2330c19173b4b5a5a736cdf Mon Sep 17 00:00:00 2001 From: Ozzieisaacs Date: Sat, 4 Jul 2020 21:22:19 +0200 Subject: [PATCH] Fix #1456 (Added route to robots.txt) --- cps/web.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cps/web.py b/cps/web.py index 4d59e61c..9af9858d 100644 --- a/cps/web.py +++ b/cps/web.py @@ -1256,6 +1256,9 @@ def render_archived_books(page, order): def get_cover(book_id): return get_book_cover(book_id) +@web.route("/robots.txt") +def get_robots(): + return send_from_directory(constants.STATIC_DIR, "robots.txt") @web.route("/show//", defaults={'anyname': 'None'}) @web.route("/show///")