diff options
author | Jo?o Duarte <jvsDuarte08@gmail.com> | 2019-07-24 11:20:35 -0700 |
---|---|---|
committer | Jo?o Duarte <jvsDuarte08@gmail.com> | 2019-07-24 11:20:35 -0700 |
commit | 5fa62c1c2a1d7ac5d17526cfdf1d1d6faa8288b2 (patch) | |
tree | ddb9bb5de5d29a25e9b5c4fdf1c8e71b5b84b575 /util | |
parent | 030787755a2d68fe2e72f28740af730c6f7450d9 (diff) | |
download | prosody-5fa62c1c2a1d7ac5d17526cfdf1d1d6faa8288b2.tar.gz prosody-5fa62c1c2a1d7ac5d17526cfdf1d1d6faa8288b2.zip |
util.prosodyctl: Created the helper function get_path_custom_plugins
Diffstat (limited to 'util')
-rw-r--r-- | util/prosodyctl.lua | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/util/prosodyctl.lua b/util/prosodyctl.lua index 5e19937e..fbeb9540 100644 --- a/util/prosodyctl.lua +++ b/util/prosodyctl.lua @@ -288,6 +288,14 @@ local function reload() return true; end +local function get_path_custom_plugins(plugin_paths) + -- I'm considering that we are using just one path to custom plugins, and it is the first in prosody.paths.plugins, for now + -- luacheck: ignore 512 + for path in plugin_paths:gmatch("[^;]+") do + return path + end +end + return { show_message = show_message; show_warning = show_message; @@ -308,4 +316,5 @@ return { start = start; stop = stop; reload = reload; + get_path_custom_plugins = get_path_custom_plugins; }; |