Skip to content

Commit 54d7d45

Browse files
Merge pull request #229 from sanjaysrikakulam/main
Update welcome.html.j2 with additional check to ensure that subdomain variable is defined
2 parents 2bfa8b9 + 6881210 commit 54d7d45

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

templates/welcome.html.j2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,12 +28,12 @@
2828
onload="this.style.position='static'; this.style.visibility='visible';"></iframe>
2929
<script type="text/javascript">
3030
var pseudo_rand = parseInt(Date.now() / 1000 / 60 / 10);
31-
{% if galaxy_themes_use_iframe is defined %}
31+
{% if galaxy_themes_use_iframe is defined and subdomain is defined and galaxy_themes_use_iframe.status == 200 %}
3232
document.getElementById('center-iframe').src = '{{ galaxy_themes_welcome_url_prefix }}{{ subdomain.name }}?nonce=' + pseudo_rand + '#';
3333
{% else %}
3434
document.getElementById('center-iframe').src = '{{ galaxy_themes_default_welcome }}?nonce=' + pseudo_rand + '#';
3535
{% endif %}
3636
</script>
3737
</body>
3838

39-
</html>
39+
</html>

0 commit comments

Comments
 (0)