projects
/
prosody.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0ba1be1
)
util.pluginloader: Return full file path from internal file loader on success, not...
author
Waqas Hussain
<waqas20@gmail.com>
Sun, 20 Feb 2011 15:01:05 +0000
(20:01 +0500)
committer
Waqas Hussain
<waqas20@gmail.com>
Sun, 20 Feb 2011 15:01:05 +0000
(20:01 +0500)
util/pluginloader.lua
patch
|
blob
|
history
diff --git
a/util/pluginloader.lua
b/util/pluginloader.lua
index 1aedd6302e1670ed9d1fc3bc93fe290a501de2ec..d955353730241dd1d3194bdcd9147d4d073668fa 100644
(file)
--- a/
util/pluginloader.lua
+++ b/
util/pluginloader.lua
@@
-20,15
+20,16
@@
local loadstring, pairs = loadstring, pairs;
module "pluginloader"
local function load_file(name)
- local file, err;
+ local file, err
, path
;
for i=1,#plugin_dir do
- file, err = io_open(plugin_dir[i]..name);
+ path = plugin_dir[i]..name;
+ file, err = io_open(path);
if file then break; end
end
if not file then return file, err; end
local content = file:read("*a");
file:close();
- return content,
name
;
+ return content,
path
;
end
function load_resource(plugin, resource, loader)