Append comments host in CSP
This commit is contained in:
@ -18,6 +18,12 @@ content="default-src 'none';
|
||||
{%- set connect_src = connect_src ~ " " ~ goatcounter_url -%}
|
||||
{%- endif %}
|
||||
|
||||
|
||||
{#- Append comments host if present -#}
|
||||
{%- if config.extra.comments -%}
|
||||
{%- set connect_src = connect_src ~ " " ~ "https://" ~ config.extra.comments.host -%}
|
||||
{%- endif -%}
|
||||
|
||||
{#- Append WebSocket for Zola serve mode -#}
|
||||
{%- if config.mode == "serve" -%}
|
||||
{%- set connect_src = connect_src ~ " ws:" -%}
|
||||
|
Reference in New Issue
Block a user