Skip to content

Commit 7802f08

Browse files
committed
Remove unnecessary to_string
1 parent 833f314 commit 7802f08

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/config.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@ impl ServerConfig {
251251

252252
/// Get [SIP002](https://github.com/shadowsocks/shadowsocks-org/issues/27) URL
253253
pub fn to_url(&self) -> String {
254-
let user_info = format!("{}:{}", self.method().to_string(), self.password());
254+
let user_info = format!("{}:{}", self.method(), self.password());
255255
let encoded_user_info = encode_config(&user_info, URL_SAFE_NO_PAD);
256256

257257
let mut url = format!("ss://{}@{}", encoded_user_info, self.addr());

0 commit comments

Comments
 (0)