Skip to main content

parse_handle

Function parse_handle 

Source
pub fn parse_handle(s: &str) -> Result<Handle>
Expand description

Parse nick@domain. Returns Err on malformed inputs or reserved nicks.

Nick rules: 2-32 chars, [a-z0-9_-]. Domain rules: DNS-label-shaped, dot-separated, lowercase ASCII. We don’t fully validate domain syntax here — DNS resolution will fail later if the operator typo’d it.