aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/xmppcomponent_listener.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/net/xmppcomponent_listener.lua b/net/xmppcomponent_listener.lua
index 5b791e65..6f02b136 100644
--- a/net/xmppcomponent_listener.lua
+++ b/net/xmppcomponent_listener.lua
@@ -203,7 +203,7 @@ function component_listener.ondisconnect(conn, err)
local session = sessions[conn];
if session then
(session.log or log)("info", "component disconnected: %s (%s)", tostring(session.host), tostring(err));
- if session.host then
+ if hosts[session.host] then
log("debug", "Deregistering component");
cm_deregister_component(session.host);
hosts[session.host].connected = nil;