Skip to content

Commit

Permalink
Merge e4de8b4 into b03eb40
Browse files Browse the repository at this point in the history
  • Loading branch information
Ahmad-Wahid committed Jun 9, 2023
2 parents b03eb40 + e4de8b4 commit 6e66ae3
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 0 deletions.
1 change: 1 addition & 0 deletions documentation/changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ New features

Bugfixes
-----------
* Fix charts not always loading over https in secured scenarios [see `PR #716 <https://www.github.com/FlexMeasures/flexmeasures/pull/716>`_]

Infrastructure / Support
----------------------
Expand Down
3 changes: 3 additions & 0 deletions flexmeasures/ui/templates/base.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@
</title>
{% endblock head %}
<meta charset="windows-1252">
{% if flask_env != 'development' and flask_env != 'testing' %}
<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests">
{% endif %}
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<link rel="icon" href="favicon.ico" type="image/x-icon" />
<link rel="shortcut icon" href="/favicon.ico" type="image/x-icon" />
Expand Down
1 change: 1 addition & 0 deletions flexmeasures/ui/utils/view_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@

def render_flexmeasures_template(html_filename: str, **variables):
"""Render template and add all expected template variables, plus the ones given as **variables."""
variables["flask_env"] = current_app.env
variables["documentation_exists"] = False
if os.path.exists(
"%s/static/documentation/html/index.html" % flexmeasures_ui.root_path
Expand Down

0 comments on commit 6e66ae3

Please sign in to comment.