aboutsummaryrefslogtreecommitdiffstats
path: root/prosodyctl
diff options
context:
space:
mode:
authorWaqas Hussain <waqas20@gmail.com>2017-09-24 18:23:45 -0400
committerWaqas Hussain <waqas20@gmail.com>2017-09-24 18:23:45 -0400
commitfcf05fde86e03966852b8be1f518ff45d092f6c7 (patch)
tree3a86da85c0ff7c8956c3dbb84edb7d67840aa47c /prosodyctl
parent2bcd4e9b0f51f6e4a6854edf1ad4aeef063ed7ca (diff)
downloadprosody-fcf05fde86e03966852b8be1f518ff45d092f6c7.tar.gz
prosody-fcf05fde86e03966852b8be1f518ff45d092f6c7.zip
prosodyctl check: Fix traceback when no modules_enabled are defined (e.g., a completely empty config)
Diffstat (limited to 'prosodyctl')
-rwxr-xr-xprosodyctl2
1 files changed, 1 insertions, 1 deletions
diff --git a/prosodyctl b/prosodyctl
index cdcd25d9..311f251e 100755
--- a/prosodyctl
+++ b/prosodyctl
@@ -1032,7 +1032,7 @@ function commands.check(arg)
suggested_global_modules = set.intersection(suggested_global_modules or set.new(options.modules_enabled), set.new(options.modules_enabled));
end
end
- if not suggested_global_modules:empty() then
+ if suggested_global_modules and not suggested_global_modules:empty() then
print(" Consider moving these modules into modules_enabled in the global section:")
print(" "..tostring(suggested_global_modules / function (x) return ("%q"):format(x) end));
end