Skip to main content

normalize_handle

Function normalize_handle 

Source
pub fn normalize_handle(input: &str) -> Result<String>
Expand description

Normalize and validate a handle: lowercase, then check it against the handle grammar and the reserved-TLD list.

Normalizing BEFORE any comparison is what makes the bidirectional check in verify_handle_claim sound; comparing raw input against a raw claim would make Alice.example and alice.example different handles.