From 2e3df14764881511025dfee43ca3e3190cf60062 Mon Sep 17 00:00:00 2001 From: C0deH4cker Date: Fri, 24 Feb 2017 13:31:53 -0500 Subject: [PATCH] Fix display of team websites with https:// prefixes (#209) --- CTFd/templates/admin/teams.html | 2 +- CTFd/templates/original/teams.html | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CTFd/templates/admin/teams.html b/CTFd/templates/admin/teams.html index 6603aeff..aaf61113 100644 --- a/CTFd/templates/admin/teams.html +++ b/CTFd/templates/admin/teams.html @@ -128,7 +128,7 @@ input[type="checkbox"] { margin: 0px !important; position: relative; top: 5px; } {{ team.name | truncate(32) }} {{ team.email | truncate(32) }} - {% if team.website and team.website.startswith('http') %}{{ team.website | truncate(32) }}{% endif %} + {% if team.website and (team.website.startswith('http://') or team.website.startswith('https://')) %}{{ team.website | truncate(32) }}{% endif %} {% if team.affiliation %}{{ team.affiliation | truncate(20) }}{% endif %} diff --git a/CTFd/templates/original/teams.html b/CTFd/templates/original/teams.html index bc9f6b97..d06cc53d 100644 --- a/CTFd/templates/original/teams.html +++ b/CTFd/templates/original/teams.html @@ -23,7 +23,7 @@ {% for team in teams %} {{ team.name }} - {% if team.website and team.website.startswith('http://') %}{{ team.website }}{% endif %} + {% if team.website and (team.website.startswith('http://') or team.website.startswith('https://')) %}{{ team.website }}{% endif %} {% if team.affiliation %}{{ team.affiliation }}{% endif %} {% if team.country %}{{ team.country }}{% endif %}