mod_storage_sql: Fix use of SQLite3 in-memory database (no path expansion)

This commit is contained in:
Kim Alvefur 2015-12-15 13:15:30 +01:00
parent 14cc4c9287
commit 275bfb45fa

View file

@ -417,7 +417,9 @@ end
local function normalize_params(params)
if params.driver == "SQLite3" then
params.database = resolve_relative_path(prosody.paths.data or ".", params.database or "prosody.sqlite");
if params.database ~= ":memory:" then
params.database = resolve_relative_path(prosody.paths.data or ".", params.database or "prosody.sqlite");
end
end
assert(params.driver and params.database, "Configuration error: Both the SQL driver and the database need to be specified");
return params;