summaryrefslogtreecommitdiffstats
path: root/web/gui/v2/registry-access.html
diff options
context:
space:
mode:
Diffstat (limited to 'web/gui/v2/registry-access.html')
-rw-r--r--web/gui/v2/registry-access.html4
1 files changed, 2 insertions, 2 deletions
diff --git a/web/gui/v2/registry-access.html b/web/gui/v2/registry-access.html
index ffa008a98..4eb327255 100644
--- a/web/gui/v2/registry-access.html
+++ b/web/gui/v2/registry-access.html
@@ -14,7 +14,7 @@
var nodes = helloData.nodes || []
var doAccess = function(mg, nm, token) {
- fetch(helloData.registry + '/api/v1/registry?action=access&machine=' + (mg || helloData.machine_guid) + '&name=' + encodeURIComponent(nm || helloData.hostname) + '&url=' + encodeURIComponent(originUrl) + '&agent=' + (helloData.agent ? helloData.agent.machine_guid : ""), { cache: "no-cache", credentials: "include", headers: { Authorization: 'Bearer ' + (token || localStorage.getItem("registry-netdata-token")) } })
+ fetch(helloData.registry + '/api/v1/registry?action=access&machine=' + (mg || helloData.machine_guid) + '&name=' + encodeURIComponent(nm || helloData.hostname) + '&url=' + encodeURIComponent(originUrl) + '&agent=' + (helloData.agent ? helloData.agent.machine_guid : ""), { cache: "no-cache", credentials: "include", headers: { ["X-Netdata-Auth"]: 'Bearer ' + (token || localStorage.getItem("registry-netdata-token")) } })
.then(function(response) { return response.json() })
.then(function(data) {
var token = data.person_guid
@@ -39,7 +39,7 @@
})
}
doAccess(helloData.machine_guid, helloData.hostname)
- })
+ }).catch(() => {})
}
try {