Comparison

core/sessionmanager.lua @ 112:df54cab4ff9c

Added: TODO
author Waqas Hussain <waqas20@gmail.com>
date Wed, 22 Oct 2008 21:20:47 +0500
parent 101:c690fa382743
child 118:76ac96c53ee5
comparison
equal deleted inserted replaced
111:0abe771b43c6 112:df54cab4ff9c
82 if not hosts[session.host].sessions[session.username] then 82 if not hosts[session.host].sessions[session.username] then
83 hosts[session.host].sessions[session.username] = { sessions = {} }; 83 hosts[session.host].sessions[session.username] = { sessions = {} };
84 else 84 else
85 if hosts[session.host].sessions[session.username].sessions[resource] then 85 if hosts[session.host].sessions[session.username].sessions[resource] then
86 -- Resource conflict 86 -- Resource conflict
87 return false, "conflict"; 87 return false, "conflict"; -- TODO kick old resource
88 end 88 end
89 end 89 end
90 90
91 session.resource = resource; 91 session.resource = resource;
92 session.full_jid = session.username .. '@' .. session.host .. '/' .. resource; 92 session.full_jid = session.username .. '@' .. session.host .. '/' .. resource;