Skip to content

Commit

Permalink
fix websocket doc
Browse files Browse the repository at this point in the history
  • Loading branch information
jxs committed Jan 9, 2025
1 parent fa33d9f commit 11c10cb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions transports/websocket/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ use rw_stream_sink::RwStreamSink;
/// );
///
/// let rcgen_cert = generate_simple_self_signed(vec!["localhost".to_string()]).unwrap();
/// let priv_key = websocket::tls::PrivateKey::new(rcgen_cert.serialize_private_key_der());
/// let cert = websocket::tls::Certificate::new(rcgen_cert.serialize_der().unwrap());
/// let priv_key = websocket::tls::PrivateKey::new(rcgen_cert.key_pair.serialize_der());
/// let cert = websocket::tls::Certificate::new(rcgen_cert.cert.der().to_vec());
/// transport.set_tls_config(websocket::tls::Config::new(priv_key, vec![cert]).unwrap());
///
/// let id = transport
Expand Down

0 comments on commit 11c10cb

Please sign in to comment.