diff options
-rw-r--r-- | plugins/mod_console.lua | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/mod_console.lua b/plugins/mod_console.lua index a46eec12..5a092298 100644 --- a/plugins/mod_console.lua +++ b/plugins/mod_console.lua @@ -127,7 +127,11 @@ function console_listener.listener(conn, data) end function console_listener.disconnect(conn, err) - + local session = sessions[conn]; + if session then + session.disconnect(); + sessions[conn] = nil; + end end connlisteners_register('console', console_listener); |