doc/example.lua: Update to use 'ready' event

Sun, 30 May 2010 02:49:58 +0100

author
Matthew Wild <mwild1@gmail.com>
date
Sun, 30 May 2010 02:49:58 +0100
changeset 77
7af3e57501c2
parent 76
927167321283
child 78
f4188eff53a7

doc/example.lua: Update to use 'ready' event

doc/example.lua file | annotate | diff | comparison | revisions
--- a/doc/example.lua	Sun May 30 02:49:02 2010 +0100
+++ b/doc/example.lua	Sun May 30 02:49:58 2010 +0100
@@ -30,8 +30,8 @@
 -- Now, actually start the connection:
 c:connect_client(jid, password);
 
--- Catch binding-success which is (currently) how you know when a stream is ready
-c:hook("binding-success", function ()
+-- Catch the "ready" event to know when the stream is ready to use
+c:hook("ready", function ()
 	print("Stream ready!");
 	c.version:set{ name = "verse example client" };
 	c:query_version(c.jid, function (v) print("I am using "..(v.name or "<unknown>")); end);

mercurial