diff --git a/turn-server/src/server/mod.rs b/turn-server/src/server/mod.rs index f81f806..c575b68 100644 --- a/turn-server/src/server/mod.rs +++ b/turn-server/src/server/mod.rs @@ -87,7 +87,7 @@ async fn fork_socket( /// let config = Config::new() /// let service = Service::new(/* ... */);; /// -/// // run(&service, config ).await? +/// // run(&service, config).await? /// ``` pub async fn run( service: &Service, diff --git a/turn/src/lib.rs b/turn/src/lib.rs index 2d43191..05b3694 100644 --- a/turn/src/lib.rs +++ b/turn/src/lib.rs @@ -221,11 +221,8 @@ impl Service { /// } /// /// let _service = Service::new( - /// Options { - /// external: "127.0.0.1:4378".parse().unwrap(), - /// realm: "test".to_string(), - /// }, /// Events {}, + /// "test".to_string(), /// ); /// ``` pub fn new(observer: T, realm: String) -> Self @@ -256,11 +253,8 @@ impl Service { /// } /// /// let service = Service::new( - /// Options { - /// external: "127.0.0.1:4378".parse().unwrap(), - /// realm: "test".to_string(), - /// }, /// Events {}, + /// "test".to_string(), /// ); /// /// tokio::spawn(service.run()).await; @@ -283,17 +277,14 @@ impl Service { /// } /// /// let service = Service::new( - /// Options { - /// external: "127.0.0.1:4378".parse().unwrap(), - /// realm: "test".to_string(), - /// }, /// Events {}, + /// "test".to_string(), /// ); /// /// tokio::spawn(service.run()); /// /// let socket = UdpSocket::bind("127.0.0.1:34254")?; - /// let mut processor = service.get_processor(); + /// let mut processor = service.get_processor("127.0.0.1:34254".into()?); /// /// let mut buf = [0; 4096]; /// let (amt, src) = socket.recv_from(&mut buf).unwrap(); diff --git a/turn/src/router/mod.rs b/turn/src/router/mod.rs index 9bc51ba..a686364 100644 --- a/turn/src/router/mod.rs +++ b/turn/src/router/mod.rs @@ -53,10 +53,7 @@ impl Router { /// } /// /// let _router = Router::new( - /// Arc::new(Options { - /// external: "127.0.0.1:4378".parse().unwrap(), - /// realm: "test".to_string(), - /// }), + /// "test".to_string(), /// Arc::new(Events {}), /// ); /// ```