taler-merchant-demos

Python-based Frontends for the Demonstration Web site
Log | Files | Refs | Submodules | README | LICENSE

commit d84c9986e4ded0f13552a508555ead951ba4f99c
parent 50284ab6039e79a42a32270a161d5a50fc09c5b1
Author: MS <ms@taler.net>
Date:   Wed, 26 Oct 2022 13:18:26 +0200

handle undefined homepage link

Diffstat:
Mtalermerchantdemos/survey/survey.py | 2--
Mtalermerchantdemos/templates/survey-base.html.j2 | 2+-
2 files changed, 1 insertion(+), 3 deletions(-)

diff --git a/talermerchantdemos/survey/survey.py b/talermerchantdemos/survey/survey.py @@ -159,8 +159,6 @@ def index(): @app.route("/<lang>/", methods=["GET"]) def start(lang): LOGGER.info("Serving main page. Currency: {}".format(CURRENCY)) - if not os.getenv("TALER_ENV_URL_MERCHANT_SURVEY"): - LOGGER.warning("TALER_ENV_URL_MERCHANT_SURVEY env variable undefined!") return flask.render_template( "survey-index.html.j2", page_title=gettext("GNU Taler Demo: Survey"), diff --git a/talermerchantdemos/templates/survey-base.html.j2 b/talermerchantdemos/templates/survey-base.html.j2 @@ -8,7 +8,7 @@ {% block header_content %} <h1> -<span class="it"><a href="{{ env('TALER_ENV_URL_MERCHANT_SURVEY') }}">{{ gettext("Survey") }}</a></span></h1> +<span class="it"><a href="{{ env('TALER_ENV_URL_MERCHANT_SURVEY', '#') }}">{{ gettext("Survey") }}</a></span></h1> <p>{{ gettext("This page demonstrates how to tip visitors for completing small tasks.") + "<br>" + gettext("Tipping is a way for offer cash rewards that go directly into a user's wallet.")