aboutsummaryrefslogtreecommitdiffstats
path: root/tools/migration/migrator/jabberd14.lua
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2012-04-29 02:10:55 +0100
committerMatthew Wild <mwild1@gmail.com>2012-04-29 02:10:55 +0100
commitbd5f9b8cbfd168a21141607218446222ab9d8642 (patch)
treee78baabff21e9b6fefaeef4a709098ca30b35922 /tools/migration/migrator/jabberd14.lua
parent9b89441dd008a8b3fda12d9217ff6f9ba240df9a (diff)
parenta2055895d362fed58ff314820bb7fddd53e40436 (diff)
downloadprosody-bd5f9b8cbfd168a21141607218446222ab9d8642.tar.gz
prosody-bd5f9b8cbfd168a21141607218446222ab9d8642.zip
Merge 0.9->trunk
Diffstat (limited to 'tools/migration/migrator/jabberd14.lua')
-rw-r--r--tools/migration/migrator/jabberd14.lua15
1 files changed, 6 insertions, 9 deletions
diff --git a/tools/migration/migrator/jabberd14.lua b/tools/migration/migrator/jabberd14.lua
index 47004a52..54c45d94 100644
--- a/tools/migration/migrator/jabberd14.lua
+++ b/tools/migration/migrator/jabberd14.lua
@@ -67,15 +67,12 @@ local parse_xml = (function()
end)();
local function load_xml(path)
- if path then
- local f, err = io_open(path);
- if not f then return f, err; end
- local data = f:read("*a");
- f:close();
- if data then
- return parse_xml(data);
- end
- end
+ local f, err = io_open(path);
+ if not f then return f, err; end
+ local data = f:read("*a");
+ f:close();
+ if not data then return; end
+ return parse_xml(data);
end
local function load_spool_file(host, filename, path)