plugins/pubsub2room.lua

changeset 88
b7f628541981
parent 86
2fa4d58349c8
child 99
072509afc701
equal deleted inserted replaced
87:5fac50efb183 88:b7f628541981
70 -- FIXME When to unsubscribe? 70 -- FIXME When to unsubscribe?
71 bot:hook("started", function() 71 bot:hook("started", function()
72 local jid = bare_jid(bot.stream.jid); 72 local jid = bare_jid(bot.stream.jid);
73 for hostnode in pairs(config) do 73 for hostnode in pairs(config) do
74 local host, node = hostnode:match("^([^#]+)#(.*)"); 74 local host, node = hostnode:match("^([^#]+)#(.*)");
75 bot.pubsub:subscribe(host, node, jid, print); 75 bot.stream.pubsub:subscribe(host, node, jid, print);
76 end 76 end
77 end); 77 end);
78 end 78 end

mercurial