aboutsummaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
authorJo?o Duarte <jvsDuarte08@gmail.com>2019-07-25 06:46:04 -0700
committerJo?o Duarte <jvsDuarte08@gmail.com>2019-07-25 06:46:04 -0700
commita0aa32c752425c9abcd0e565722818ea73ddaf90 (patch)
tree07ab8a133e605ab1e344414164eebe1d41f8e468 /util
parent9cf38b7ed5b58856d9dd2298834feaa7501cfa6e (diff)
downloadprosody-a0aa32c752425c9abcd0e565722818ea73ddaf90.tar.gz
prosody-a0aa32c752425c9abcd0e565722818ea73ddaf90.zip
util.startup: Removed unnecessary if clause at startup.set_plugindir
Diffstat (limited to 'util')
-rw-r--r--util/startup.lua16
1 files changed, 7 insertions, 9 deletions
diff --git a/util/startup.lua b/util/startup.lua
index 65a131fe..54b968f8 100644
--- a/util/startup.lua
+++ b/util/startup.lua
@@ -235,17 +235,15 @@ function startup.setup_plugindir()
CFG_PLUGINDIR = table.concat(custom_plugin_paths, path_sep)..path_sep..(CFG_PLUGINDIR or "plugins");
prosody.paths.plugins = CFG_PLUGINDIR;
end
- if installer_plugin_paths then
- for path, _ in ipairs(installer_plugin_paths) do
- if os.execute('[ -d "'..installer_plugin_paths[path]..'" ]') ~= 0 then
- os.execute("mkdir "..installer_plugin_paths[path])
- end
+ for path, _ in ipairs(installer_plugin_paths) do
+ if os.execute('[ -d "'..installer_plugin_paths[path]..'" ]') ~= 0 then
+ os.execute("mkdir "..installer_plugin_paths[path])
end
- local path_sep = package.config:sub(3,3);
- -- luacheck: ignore 111
- CFG_PLUGINDIR = table.concat(installer_plugin_paths, path_sep)..path_sep..(CFG_PLUGINDIR or "plugins");
- prosody.paths.plugins = CFG_PLUGINDIR;
end
+ local path_sep = package.config:sub(3,3);
+ -- luacheck: ignore 111
+ CFG_PLUGINDIR = table.concat(installer_plugin_paths, path_sep)..path_sep..(CFG_PLUGINDIR or "plugins");
+ prosody.paths.plugins = CFG_PLUGINDIR;
end
function startup.chdir()