Fix double slashes in URIs (#558)
This commit is contained in:
parent
239ff6cb60
commit
da565b3bfc
|
@ -6,7 +6,7 @@ from .methods import is_mediacms_editor, is_mediacms_manager
|
|||
def stuff(request):
|
||||
"""Pass settings to the frontend"""
|
||||
ret = {}
|
||||
ret["FRONTEND_HOST"] = request.build_absolute_uri('/')
|
||||
ret["FRONTEND_HOST"] = request.build_absolute_uri('/').rstrip('/')
|
||||
ret["DEFAULT_THEME"] = settings.DEFAULT_THEME
|
||||
ret["PORTAL_NAME"] = settings.PORTAL_NAME
|
||||
ret["PORTAL_DESCRIPTION"] = settings.PORTAL_DESCRIPTION
|
||||
|
|
|
@ -2,7 +2,7 @@ MediaCMS.site = {
|
|||
id: 'mediacms',
|
||||
title: "{{PORTAL_NAME}}",
|
||||
url: '{{FRONTEND_HOST}}',
|
||||
api: '{{FRONTEND_HOST}}api/v1',
|
||||
api: '{{FRONTEND_HOST}}/api/v1',
|
||||
theme: {
|
||||
mode: '{{DEFAULT_THEME}}',
|
||||
switch: {
|
||||
|
|
Loading…
Reference in a new issue