mirror of
https://github.com/tokio-rs/axum.git
synced 2026-08-25 00:00:23 +02:00
Change Connected::connect_info to return Self (#396)
I've been thinking that having an associated type probably isn't necessary. I imagine most users are either using `SocketAddr` to the remote connection IP, or writing their own connection struct.
This commit is contained in:
+1
-3
@@ -429,9 +429,7 @@ impl<S> Router<S> {
|
||||
/// }
|
||||
///
|
||||
/// impl Connected<&AddrStream> for MyConnectInfo {
|
||||
/// type ConnectInfo = MyConnectInfo;
|
||||
///
|
||||
/// fn connect_info(target: &AddrStream) -> Self::ConnectInfo {
|
||||
/// fn connect_info(target: &AddrStream) -> Self {
|
||||
/// MyConnectInfo {
|
||||
/// // ...
|
||||
/// }
|
||||
|
||||
Reference in New Issue
Block a user