1
0
Fork 0
mirror of https://github.com/denoland/deno.git synced 2025-01-03 04:48:52 -05:00

trim_left_matches (deprecated) => trim_start_matches (#1524)

This commit is contained in:
Kevin (Kun) "Kassimo" Qian 2019-01-14 18:21:36 -08:00 committed by Ryan Dahl
parent eb4a19ef6e
commit f9c7c921af

View file

@ -85,7 +85,7 @@ fn split<'a>(address: &'a str) -> Option<(&'a str, u16)> {
addr addr
}; };
let p = p.trim_left_matches(':'); let p = p.trim_start_matches(':');
match p.parse::<u16>() { match p.parse::<u16>() {
Err(_) => None, Err(_) => None,
Ok(port) => Some((addr, port)), Ok(port) => Some((addr, port)),