pub fn from_public_key_hex(hex: String)
        -> Result<DiscoveryKeyWasm, JsError>
    {
        let bytes = hex::decode(&hex)?;
        let public = PublicKey::from_bytes(&bytes)?;
        let key = discovery_key(public.as_bytes());
        Ok(DiscoveryKeyWasm { key })
    }
/// Create from a public key hex [String].
Create from a public key hex [String].
Create from a public key hex [ String ] .
pub fn from_public_key_hex(hex: String)
        -> Result<DiscoveryKeyWasm, JsError>
    {
        let bytes = hex::decode(&hex)?;
        let public = PublicKey::from_bytes(&bytes)?;
        let key = discovery_key(public.as_bytes());
        Ok(DiscoveryKeyWasm { key })
    }
pub fn from_public_key_hex ( hex : String ) -> Result < DiscoveryKeyWasm , JsError > { let bytes = hex :: decode ( & hex ) ? ; let public = PublicKey :: from_bytes ( & bytes ) ? ; let key = discovery_key ( public . as_bytes ( ) ) ; Ok ( DiscoveryKeyWasm { key } ) }
Create from a public key hex [String].
Create from a public key hex [ String ] .
hex
String
hex
String