From 8537b61f38fd3976d47b153f3548f77896e42eb6 Mon Sep 17 00:00:00 2001 From: Till Hoeppner Date: Sun, 28 Jun 2015 21:36:21 +0200 Subject: Fix 01.rs for new API --- examples/01.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'examples') diff --git a/examples/01.rs b/examples/01.rs index 2f82839..33c2fcf 100644 --- a/examples/01.rs +++ b/examples/01.rs @@ -29,7 +29,7 @@ fn callback(server: &mut Client, msg: &Message, event: Option) { } }, Some(Event::Reply(RPL_WELCOME(_))) => { - server.join("#botzoo", None); + server.join("#meep!", None); }, _ => () } @@ -37,11 +37,11 @@ fn callback(server: &mut Client, msg: &Message, event: Option) { fn main() { env_logger::init().unwrap(); - let mut s = Client::new(); + let mut s = OwnedClient::new(); let ssl = Ssl::new(&SslContext::new(SslMethod::Tlsv1).unwrap()).unwrap(); s.connect_ssl("irc.mozilla.org", 6697, ssl); - s.register(NAME, NAME, DESC); + s.register(NAME, NAME, DESC, None); // Dedicate this thread to listening and event processing - s.listen(Some(callback)); + s.listen_with_callback(callback); } -- cgit v1.2.3