aboutsummaryrefslogtreecommitdiffstats
path: root/util
diff options
context:
space:
mode:
authorJoão Duarte <jvsDuarte08@gmail.com>2019-08-16 13:54:40 -0700
committerJoão Duarte <jvsDuarte08@gmail.com>2019-08-16 13:54:40 -0700
commitebfdb94d96f23b2953b69b0991985bf44691f747 (patch)
tree35c1e0414cd4bc136a08731b31b3338df1908b89 /util
parentbb07c44d5a0dbd76fc9c4650a8fdef383d127ad2 (diff)
downloadprosody-ebfdb94d96f23b2953b69b0991985bf44691f747.tar.gz
prosody-ebfdb94d96f23b2953b69b0991985bf44691f747.zip
util.pluginloader: Added a new path to the variable local_names
Diffstat (limited to 'util')
-rw-r--r--util/pluginloader.lua3
1 files changed, 2 insertions, 1 deletions
diff --git a/util/pluginloader.lua b/util/pluginloader.lua
index 9ab8f245..af0428c4 100644
--- a/util/pluginloader.lua
+++ b/util/pluginloader.lua
@@ -36,12 +36,13 @@ end
local function load_resource(plugin, resource)
resource = resource or "mod_"..plugin..".lua";
-
+ local lua_version = _VERSION:match(" (.+)$");
local names = {
"mod_"..plugin..dir_sep..plugin..dir_sep..resource; -- mod_hello/hello/mod_hello.lua
"mod_"..plugin..dir_sep..resource; -- mod_hello/mod_hello.lua
plugin..dir_sep..resource; -- hello/mod_hello.lua
resource; -- mod_hello.lua
+ "share"..dir_sep.."lua"..dir_sep..lua_version..dir_sep.."mod_"..plugin..dir_sep..resource;
};
return load_file(names);