public static IDestination CashAddrToDestination(string address, Network expectedNetwork) { BchAddr.BchAddrData bchAddr = BchAddr.DecodeCashAddressWithPrefix(address); var result = new KeyId(bchAddr.Hash); return(result); }
public static IDestination CashAddrToDestination(string address, Network expectedNetwork, bool fP2Sh = false) { BchAddr.BchAddrData bchAddr = BchAddr.DecodeCashAddressWithPrefix(address); if (fP2Sh) { return(new ScriptId(bchAddr.Hash)); } else { return(new KeyId(bchAddr.Hash)); } }