diff options
Diffstat (limited to 'src/hydrilla/proxy')
-rw-r--r-- | src/hydrilla/proxy/policies/payload_resource.py | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/hydrilla/proxy/policies/payload_resource.py b/src/hydrilla/proxy/policies/payload_resource.py index 70844e6..7fdc7ac 100644 --- a/src/hydrilla/proxy/policies/payload_resource.py +++ b/src/hydrilla/proxy/policies/payload_resource.py @@ -64,13 +64,12 @@ import json from threading import Lock from base64 import b64encode from urllib.parse import quote, parse_qs, urlparse, urlencode, urljoin -from itertools import takewhile import jinja2 from ...translations import smart_gettext as _ from ...url_patterns import ParsedUrl -from ..._version import version_tuple +from ...versions import haketilo_version from .. import state from .. import http_messages from . import base @@ -281,8 +280,7 @@ class PayloadResourcePolicy(PayloadAwarePolicy): template = jinja_env.get_template('page_init_script.js.jinja') token = self.payload_data.unique_token base_url = self.assets_base_url(request_info.url) - ver = [*takewhile(lambda i: isinstance(i, int), version_tuple)] - ver_str = json.dumps(ver) + ver_str = json.dumps(haketilo_version) js = template.render( unique_token_encoded = encode_string_for_js(token), assets_base_url_encoded = encode_string_for_js(base_url), |