diff --git a/cms/envs/aws.py b/cms/envs/aws.py index 7d596194f4..9a37a44a92 100644 --- a/cms/envs/aws.py +++ b/cms/envs/aws.py @@ -90,7 +90,10 @@ with open(CONFIG_ROOT / CONFIG_PREFIX + "env.json") as env_file: STATIC_URL_BASE = ENV_TOKENS.get('STATIC_URL_BASE', None) if STATIC_URL_BASE: # collectstatic will fail if STATIC_URL is a unicode string - STATIC_URL = STATIC_URL_BASE.encode('ascii') + "/" + git.revision + "/" + STATIC_URL = STATIC_URL_BASE.encode('ascii') + if not STATIC_URL.endswith("/"): + STATIC_URL += "/" + STATIC_URL += git.revision + "/" # GITHUB_REPO_ROOT is the base directory # for course data diff --git a/lms/envs/aws.py b/lms/envs/aws.py index 2b7f309ea8..0e3e87b299 100644 --- a/lms/envs/aws.py +++ b/lms/envs/aws.py @@ -124,7 +124,9 @@ if STATIC_ROOT_BASE: STATIC_URL_BASE = ENV_TOKENS.get('STATIC_URL_BASE', None) if STATIC_URL_BASE: # collectstatic will fail if STATIC_URL is a unicode string - STATIC_URL = STATIC_URL_BASE.encode('ascii') + "/" + STATIC_URL = STATIC_URL_BASE.encode('ascii') + if not STATIC_URL.endswith("/"): + STATIC_URL += "/" PLATFORM_NAME = ENV_TOKENS.get('PLATFORM_NAME', PLATFORM_NAME) # For displaying on the receipt. At Stanford PLATFORM_NAME != MERCHANT_NAME, but PLATFORM_NAME is a fine default diff --git a/lms/templates/footer.html b/lms/templates/footer.html index caff83bace..3e8e993891 100644 --- a/lms/templates/footer.html +++ b/lms/templates/footer.html @@ -48,27 +48,27 @@