11:a502c905527c | 12:1793fca3d707 |
---|---|
1 return function (opts, args) | |
2 local function on_message(message) | |
3 local body = message:get_child("body"); | |
4 if body then | |
5 print(body:get_text()); | |
6 end | |
7 end | |
8 local function on_connect(conn) | |
9 conn:hook("message", on_message); | |
10 conn:send(verse.presence()); | |
11 end | |
12 clix_connect(opts, on_connect); | |
13 end |