aboutsummaryrefslogtreecommitdiff
path: root/gn_auth/misc_views.py
diff options
context:
space:
mode:
Diffstat (limited to 'gn_auth/misc_views.py')
-rw-r--r--gn_auth/misc_views.py11
1 files changed, 10 insertions, 1 deletions
diff --git a/gn_auth/misc_views.py b/gn_auth/misc_views.py
index bd2ad62..2abad4a 100644
--- a/gn_auth/misc_views.py
+++ b/gn_auth/misc_views.py
@@ -2,9 +2,10 @@
Miscellaneous top-level views that have nothing to do with the application's
functionality.
"""
+import os
from pathlib import Path
-from flask import Blueprint
+from flask import Blueprint, current_app as app, send_from_directory
misc = Blueprint("misc", __name__)
@@ -16,3 +17,11 @@ def version():
with open(version_file, encoding="utf-8") as verfl:
return verfl.read().strip()
return "0.0.0"
+
+
+@misc.route("/favicon.ico", methods=["GET"])
+def favicon():
+ """Return the favicon."""
+ return send_from_directory(os.path.join(app.root_path, "static"),
+ "images/CITGLogo.png",
+ mimetype="image/png")