Skip to main content

parse_contract_address

Function parse_contract_address 

Source
pub fn parse_contract_address(flag_name: &str, raw: &str) -> Result<String>
Expand description

Validate a user-supplied EVM contract address string.

Requires 0x prefix, 40 hex characters, and a correct EIP-55 checksum. Returns the canonical checksummed form. Public so callers that generate config (e.g. decdn config init --chain) can apply the same check to baked-in addresses.