aboutsummaryrefslogtreecommitdiffstats
path: root/core/rostermanager.lua
diff options
context:
space:
mode:
authorWaqas Hussain <waqas20@gmail.com>2009-10-22 03:34:50 +0500
committerWaqas Hussain <waqas20@gmail.com>2009-10-22 03:34:50 +0500
commitfefe960849623d219392f5d9f14df7892ce29d00 (patch)
tree1bce846b57719febf02846b528bc4bcb33a9a145 /core/rostermanager.lua
parenta44b6261c9f4fa59f6fc057cd7965c6ce1f2cdb1 (diff)
downloadprosody-fefe960849623d219392f5d9f14df7892ce29d00.tar.gz
prosody-fefe960849623d219392f5d9f14df7892ce29d00.zip
rostermanager: Ensure meta-data entry is present on roster load.
Diffstat (limited to 'core/rostermanager.lua')
-rw-r--r--core/rostermanager.lua1
1 files changed, 1 insertions, 0 deletions
diff --git a/core/rostermanager.lua b/core/rostermanager.lua
index 54c97083..b415c21c 100644
--- a/core/rostermanager.lua
+++ b/core/rostermanager.lua
@@ -99,6 +99,7 @@ function load_roster(username, host)
-- Attempt to load roster for non-loaded user
log("debug", "load_roster: loading for offline user: "..username.."@"..host);
roster = datamanager.load(username, host, "roster") or {};
+ if not roster[false] then roster[false] = { }; end
roster[username.."@"..host] = nil;
hosts[host].events.fire_event("roster-load", username, host, roster);
return roster;