diff --git a/src/access.c b/src/access.c index 2859b2cd..74725758 100644 --- a/src/access.c +++ b/src/access.c @@ -46,7 +46,7 @@ struct access_ticket_queue access_tickets; const char *superuser_username; const char *superuser_password; -static int access_noacl; +int access_noacl; /** * diff --git a/src/webui/comet.c b/src/webui/comet.c index f8a2231a..dd6b4dff 100644 --- a/src/webui/comet.c +++ b/src/webui/comet.c @@ -138,12 +138,15 @@ comet_mailbox_create(void) static void comet_access_update(http_connection_t *hc, comet_mailbox_t *cmb) { + extern int access_noacl; + htsmsg_t *m = htsmsg_create_map(); const char *username = hc->hc_access ? (hc->hc_access->aa_username ?: "") : ""; htsmsg_add_str(m, "notificationClass", "accessUpdate"); - htsmsg_add_str(m, "username", username); + if (!access_noacl) + htsmsg_add_str(m, "username", username); htsmsg_add_u32(m, "dvr", !http_access_verify(hc, ACCESS_RECORDER)); htsmsg_add_u32(m, "admin", !http_access_verify(hc, ACCESS_ADMIN)); diff --git a/src/webui/static/app/tvheadend.js b/src/webui/static/app/tvheadend.js index 2a9e40be..2a9e6256 100644 --- a/src/webui/static/app/tvheadend.js +++ b/src/webui/static/app/tvheadend.js @@ -311,7 +311,8 @@ function accessUpdate(o) { if (!tvheadend.capabilities) return; - tvheadend.rootTabPanel.setLogin(o.username); + if ('username' in o) + tvheadend.rootTabPanel.setLogin(o.username); if (tvheadend.autorecButton) tvheadend.autorecButton.setDisabled(o.dvr != true); @@ -514,8 +515,6 @@ tvheadend.RootTabPanel = Ext.extend(Ext.TabPanel, { if (p == this.loginItem || p == this.loginCmdItem) return false; }); - - this.setLogin(''); }, getComponent: function(comp) {