summaryrefslogtreecommitdiff
path: root/talermerchantdemos/httpcommon/__init__.py
diff options
context:
space:
mode:
authorms <ms@taler.net>2022-04-25 14:53:03 +0200
committerms <ms@taler.net>2022-04-25 14:53:03 +0200
commitb701e627779710116b8c16af943601314df5a5db (patch)
tree242929c173ac294b0dfd4db3f201da4f610f8f3a /talermerchantdemos/httpcommon/__init__.py
parent45c35038dbf36bcbed4f9ff5e3c9bc02b4164747 (diff)
downloadtaler-merchant-demos-master.tar.gz
taler-merchant-demos-master.tar.bz2
taler-merchant-demos-master.zip
Manually defining redirected URLs.HEADmaster
Newer versions of Werkzueg do _not_ transparently prefix redirects with the value of X-Forward-Prefix _anymore_.
Diffstat (limited to 'talermerchantdemos/httpcommon/__init__.py')
-rw-r--r--talermerchantdemos/httpcommon/__init__.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/talermerchantdemos/httpcommon/__init__.py b/talermerchantdemos/httpcommon/__init__.py
index 0584cba..ca61b66 100644
--- a/talermerchantdemos/httpcommon/__init__.py
+++ b/talermerchantdemos/httpcommon/__init__.py
@@ -199,3 +199,7 @@ def make_utility_processor(pagename):
)
return utility_processor
+
+# Ask the env the value of X-Forwarded-Prefix.
+def get_app_root():
+ return flask.request.environ.get("SCRIPT_NAME", "")