From 5aa4dda0fb32d81ee08d873bd9528ab26aa56c22 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jo=C3=A3o=20Duarte?= Date: Wed, 31 Jul 2019 11:08:43 -0700 Subject: util.prosodyctl: The check_flags function now considers that a module, if given, is specified at the penultimate argument it receives --- util/prosodyctl.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'util') 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) -- cgit v1.2.3