Skip to content

Commit d976c3b

Browse files
committed
fix build
1 parent 38ab1bc commit d976c3b

File tree

2 files changed

+7
-8
lines changed

2 files changed

+7
-8
lines changed

src/extension.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,11 @@ fn parse_extension(
102102
if !s.contains(prefix) {
103103
return None;
104104
}
105-
let s = if trim { s.trim_start_matches(prefix) } else { s };
105+
let s = if trim {
106+
s.trim_start_matches(prefix)
107+
} else {
108+
s
109+
};
106110
let extension = handler(s);
107111
tracing::trace!("Extension: {:?}", extension);
108112
Some(extension)

src/socks/server/auth.rs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,7 @@ use crate::{
33
socks::proto::{AsyncStreamOperation, Method, UsernamePassword, handshake::password},
44
};
55
use password::{Request, Response, Status::*};
6-
use std::{
7-
future::Future,
8-
io::Error,
9-
};
6+
use std::{future::Future, io::Error};
107
use tokio::net::TcpStream;
118

129
pub trait Auth: Send {
@@ -107,9 +104,7 @@ impl Auth for PasswordAuth {
107104

108105
Ok((true, extension))
109106
} else {
110-
Err(Error::other(
111-
"username or password is incorrect",
112-
))
107+
Err(Error::other("username or password is incorrect"))
113108
}
114109
}
115110
}

0 commit comments

Comments
 (0)