pub fn is_on_correct_network(addr: Address, network_flag: bool) -> bool
Expand description
Determines whether the given address belongs to the correct Cardano network.
Checks if the provided address matches the expected network based on the network_flag
.
§Arguments
addr
- A Cardano address to verify.network_flag
- A boolean flag indicating the expected network:true
checks for Testnet.false
checks for Mainnet.
§Returns
true
if the address matches the expected network.false
otherwise.