Skip to main content

split_host_and_inline_port

Function split_host_and_inline_port 

fn split_host_and_inline_port(host: &str) -> (&str, Option<u16>)
Expand description

Splits host on its trailing :port suffix (if any) and parses the port. An invalid :port is logged and treated as absent so the CLI port can still apply.

§Arguments

  • host - Raw host argument, optionally with :port suffix.

§Returns

(host_without_port, inline_port).