plugins/urltitle.lua

changeset 94
5cc3b481d3e7
parent 92
37e804dfaf37
child 115
6498ca5ed831
equal deleted inserted replaced
93:ab58062505e2 94:5cc3b481d3e7
10 local title = data:match("<title[^>]*>([^<]+)"); 10 local title = data:match("<title[^>]*>([^<]+)");
11 11
12 if title then 12 if title then
13 title = title:gsub("\n", ""); 13 title = title:gsub("\n", "");
14 if message.room then 14 if message.room then
15 message.room:send(title); 15 message.room:send_message(title)
16 else 16 else
17 message:reply(title); 17 message:reply(title);
18 end 18 end
19 end 19 end
20 end); 20 end);

mercurial