Skip to main content

canonicalize_email

Function canonicalize_email 

Source
pub fn canonicalize_email(address: &str) -> Result<String>
Expand description

Canonicalizes an email address for storage and matching.

Both components are lowercased, and ß is expanded to ss, so Strauß@Example.com and strauss@example.com share one key.

Returns an error when the address exceeds MAX_EMAIL_LEN bytes or its final @ does not separate nonempty local and domain parts.