diff --git a/api/router_static.go b/api/router_static.go index 59038b7..eb9be62 100644 --- a/api/router_static.go +++ b/api/router_static.go @@ -49,8 +49,8 @@ func initStaticRouter(router *mux.Router) error { prefix := "" if dir == "/js" { - prefix = "window.commento_origin='" + os.Getenv("ORIGIN") + "';\n" - prefix += "window.commento_cdn='" + os.Getenv("CDN_PREFIX") + "';\n" + prefix = "window.commentoOrigin='" + os.Getenv("ORIGIN") + "';\n" + prefix += "window.commentoCdn='" + os.Getenv("CDN_PREFIX") + "';\n" } gzip := (os.Getenv("GZIP_STATIC") == "true") diff --git a/frontend/js/commento.js b/frontend/js/commento.js index 202c302..93959f2 100644 --- a/frontend/js/commento.js +++ b/frontend/js/commento.js @@ -50,8 +50,8 @@ var ID_FOOTER = "commento-footer"; - var origin = global.commento_origin; - var cdn = global.commento_cdn; + var origin = global.commentoOrigin; + var cdn = global.commentoCdn; var root = null; var cssOverride = undefined; var isAuthenticated = false; diff --git a/frontend/js/dashboard-domain.js b/frontend/js/dashboard-domain.js index 5855674..bba3709 100644 --- a/frontend/js/dashboard-domain.js +++ b/frontend/js/dashboard-domain.js @@ -42,7 +42,7 @@ } global.buttonDisable("#add-site-button"); - global.post(global.commento_origin + "/api/domain/new", json, function(resp) { + global.post(global.commentoOrigin + "/api/domain/new", json, function(resp) { global.buttonEnable("#add-site-button"); $("#new-domain-name").val(""); @@ -69,7 +69,7 @@ session: global.cookieGet("session"), }; - global.post(global.commento_origin + "/api/domain/list", json, function(resp) { + global.post(global.commentoOrigin + "/api/domain/list", json, function(resp) { if (!resp.success) { global.globalErrorShow(resp.message); return; @@ -111,7 +111,7 @@ domain: domain, }; - global.post(global.commento_origin + "/api/domain/update", json, function(resp) { + global.post(global.commentoOrigin + "/api/domain/update", json, function(resp) { if (callback !== undefined) callback(resp.success); @@ -130,7 +130,7 @@ domain: domain, }; - global.post(global.commento_origin + "/api/domain/delete", json, function(resp) { + global.post(global.commentoOrigin + "/api/domain/delete", json, function(resp) { if (!resp.success) { global.globalErrorShow(resp.message); return; diff --git a/frontend/js/dashboard-import.js b/frontend/js/dashboard-import.js index 8bdaf07..2f8e4aa 100644 --- a/frontend/js/dashboard-import.js +++ b/frontend/js/dashboard-import.js @@ -18,7 +18,7 @@ } global.buttonDisable("#disqus-import-button"); - global.post(global.commento_origin + "/api/domain/import/disqus", json, function(resp) { + global.post(global.commentoOrigin + "/api/domain/import/disqus", json, function(resp) { global.buttonEnable("#disqus-import-button"); if (!resp.success) { diff --git a/frontend/js/dashboard-installation.js b/frontend/js/dashboard-installation.js index 58559f2..d50a728 100644 --- a/frontend/js/dashboard-installation.js +++ b/frontend/js/dashboard-installation.js @@ -6,7 +6,7 @@ var html = '' + '
\n' + - '