diff options
author | Cédric Bonhomme <cedric@cedricbonhomme.org> | 2022-04-25 14:02:29 +0200 |
---|---|---|
committer | Cédric Bonhomme <cedric@cedricbonhomme.org> | 2022-04-25 14:02:29 +0200 |
commit | 51a4e7b1f0fb1267d4d84e5239ed068e40efda00 (patch) | |
tree | 28f0e2fbcd9d81b12b74363b4fd01f9cf93260ee | |
parent | updated moment.js (diff) | |
download | newspipe-51a4e7b1f0fb1267d4d84e5239ed068e40efda00.tar.gz newspipe-51a4e7b1f0fb1267d4d84e5239ed068e40efda00.tar.bz2 newspipe-51a4e7b1f0fb1267d4d84e5239ed068e40efda00.zip |
added robots dot txt page.
-rw-r--r-- | newspipe/templates/robots.txt | 2 | ||||
-rw-r--r-- | newspipe/web/views/views.py | 6 |
2 files changed, 8 insertions, 0 deletions
diff --git a/newspipe/templates/robots.txt b/newspipe/templates/robots.txt new file mode 100644 index 00000000..1f53798b --- /dev/null +++ b/newspipe/templates/robots.txt @@ -0,0 +1,2 @@ +User-agent: * +Disallow: / diff --git a/newspipe/web/views/views.py b/newspipe/web/views/views.py index 02f4cad8..7ff2a2e4 100644 --- a/newspipe/web/views/views.py +++ b/newspipe/web/views/views.py @@ -119,3 +119,9 @@ def about_more(): talisman.content_security_policy ), ) + + +@current_app.route("/robots.txt", methods=["GET"]) +def robots(): + """Robots dot txt page.""" + return render_template("robots.txt"), 200, {"Content-Type": "text/plain"} |