aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2022-10-23 16:19:39 +0200
committerKim Alvefur <zash@zash.se>2022-10-23 16:19:39 +0200
commitc51152432a24b2030d19b002734df9046b7a076c (patch)
treecae6d26b813ec3a68203b7015bdeedb0efcd16a3
parentbab0635179f291387505721d2a9acc7f9086d7cd (diff)
downloadprosody-c51152432a24b2030d19b002734df9046b7a076c.tar.gz
prosody-c51152432a24b2030d19b002734df9046b7a076c.zip
mod_admin_shell: Ensure connection exists to get port from (fixes #1777)
-rw-r--r--plugins/mod_admin_shell.lua6
1 files changed, 5 insertions, 1 deletions
diff --git a/plugins/mod_admin_shell.lua b/plugins/mod_admin_shell.lua
index f8fa7242..bd84658d 100644
--- a/plugins/mod_admin_shell.lua
+++ b/plugins/mod_admin_shell.lua
@@ -745,7 +745,11 @@ available_columns = {
width = 5;
align = "right";
key = "conn";
- mapper = function(conn) return conn:serverport(); end;
+ mapper = function(conn)
+ if conn then
+ return conn:serverport();
+ end
+ end;
};
dir = {
title = "Dir";