We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e44c3e3 commit d809d1fCopy full SHA for d809d1f
my-http-server-core/src/http_server.rs
@@ -59,9 +59,9 @@ impl MyHttpServer {
59
}
60
61
#[cfg(unix)]
62
- pub fn new_as_unix_socket(unix_socket_addr: String) -> Self {
+ pub fn new_as_unix_socket(unix_socket_addr: impl Into<String>) -> Self {
63
Self {
64
- addr: ListenAddr::Unix(Arc::new(unix_socket_addr)),
+ addr: ListenAddr::Unix(Arc::new(unix_socket_addr.into())),
65
middlewares: Some(Vec::new()),
66
tech_middlewares: Some(Vec::new()),
67
connections: Arc::new(AtomicI64::new(0)),
0 commit comments