aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2019-01-04 13:41:39 +0100
committerKim Alvefur <zash@zash.se>2019-01-04 13:41:39 +0100
commitf902e414f63ae70f74c414a57c0c3cfe26ba693d (patch)
tree26741f250b0d7c139544958b5d088ecc79bb9ee3
parentce8379079e7e0fae9b292a7a8ce6ddd91a4f6e46 (diff)
downloadprosody-f902e414f63ae70f74c414a57c0c3cfe26ba693d.tar.gz
prosody-f902e414f63ae70f74c414a57c0c3cfe26ba693d.zip
mod_admin_telnet: Serialize config values (table: 0x123abc isn't useful)
-rw-r--r--plugins/mod_admin_telnet.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/plugins/mod_admin_telnet.lua b/plugins/mod_admin_telnet.lua
index c6b67b95..cd9f8078 100644
--- a/plugins/mod_admin_telnet.lua
+++ b/plugins/mod_admin_telnet.lua
@@ -32,6 +32,7 @@ local envload = require "util.envload".envload;
local envloadfile = require "util.envload".envloadfile;
local has_pposix, pposix = pcall(require, "util.pposix");
local async = require "util.async";
+local serialize = require "util.serialization".new({ fatal = false, unquoted = true});
local commands = module:shared("commands")
local def_env = module:shared("env");
@@ -500,7 +501,7 @@ function def_env.config:get(host, key)
host, key = "*", host;
end
local config_get = require "core.configmanager".get
- return true, tostring(config_get(host, key));
+ return true, serialize(config_get(host, key));
end
function def_env.config:reload()