aboutsummaryrefslogtreecommitdiffstats
path: root/tools/openfire2prosody.lua
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2023-06-08 09:37:01 +0200
committerKim Alvefur <zash@zash.se>2023-06-08 09:37:01 +0200
commit1541284108b73abc332a7930eff3dc4d5fc5490b (patch)
treeb4cdfc948f6112e9bd47d2b41ff90c358ca57c52 /tools/openfire2prosody.lua
parent0d6c625f935a28a94ae8893747d4fdbeb1e53d87 (diff)
downloadprosody-1541284108b73abc332a7930eff3dc4d5fc5490b.tar.gz
prosody-1541284108b73abc332a7930eff3dc4d5fc5490b.zip
tools: Update imports to use new prosody.* namespace
Diffstat (limited to 'tools/openfire2prosody.lua')
-rw-r--r--tools/openfire2prosody.lua8
1 files changed, 6 insertions, 2 deletions
diff --git a/tools/openfire2prosody.lua b/tools/openfire2prosody.lua
index cd3e62e5..2d8c6867 100644
--- a/tools/openfire2prosody.lua
+++ b/tools/openfire2prosody.lua
@@ -15,6 +15,10 @@ if my_name:match("[/\\]") then
package.cpath = package.cpath..";"..my_name:gsub("[^/\\]+$", "../?.so");
end
+if not pcall(require, "prosody.loader") then
+ pcall(require, "loader");
+end
+
-- ugly workaround for getting datamanager to work outside of prosody :(
prosody = { };
prosody.platform = "unknown";
@@ -24,12 +28,12 @@ elseif package.config:sub(1,1) == "/" then
prosody.platform = "posix";
end
-local parse_xml = require "util.xml".parse;
+local parse_xml = require "prosody.util.xml".parse;
-----------------------------------------------------------------------
package.loaded["util.logger"] = {init = function() return function() end; end}
-local dm = require "util.datamanager"
+local dm = require "prosody.util.datamanager"
dm.set_data_path("data");
local arg = ...;