aboutsummaryrefslogtreecommitdiffstats
path: root/util/prosodyctl.lua
diff options
context:
space:
mode:
authorJoão Duarte <jvsDuarte08@gmail.com>2019-07-31 11:08:43 -0700
committerJoão Duarte <jvsDuarte08@gmail.com>2019-07-31 11:08:43 -0700
commit5aa4dda0fb32d81ee08d873bd9528ab26aa56c22 (patch)
tree09c0017316a58035ed1da7cc7840da7414fa4c09 /util/prosodyctl.lua
parent5ba7a798fbf368a845cfc3fd04c3241d29f75d53 (diff)
downloadprosody-5aa4dda0fb32d81ee08d873bd9528ab26aa56c22.tar.gz
prosody-5aa4dda0fb32d81ee08d873bd9528ab26aa56c22.zip
util.prosodyctl: The check_flags function now considers that a module, if given, is specified at the penultimate argument it receives
Diffstat (limited to 'util/prosodyctl.lua')
-rw-r--r--util/prosodyctl.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/util/prosodyctl.lua b/util/prosodyctl.lua
index 274d611c..bf65e396 100644
--- a/util/prosodyctl.lua
+++ b/util/prosodyctl.lua
@@ -301,9 +301,9 @@ local function check_flags(arg)
-- There might not be any argument when the list command is calling this function
if arg[1] and arg[1]:sub(1, #flag) == flag then
local dir = arg[1]:match("=(.+)$")
- return true, arg[2], dir;
+ return true, arg[#arg-1], dir;
end
- return false, arg[1]
+ return false, arg[#arg-1];
end
local function call_luarocks(operation, mod, dir)