Make ln peers configurable
[rapid-gossip-sync-server] / src / hex_utils.rs
index 36f2779b02f0efc7f04ba5077648c6301c9861bb..be55839d8639d0965b6634b0afe94e2c620000b8 100644 (file)
@@ -1,5 +1,3 @@
-use bitcoin::secp256k1::PublicKey;
-
 pub fn to_vec(hex: &str) -> Option<Vec<u8>> {
     let mut out = Vec::with_capacity(hex.len() / 2);
 
@@ -20,14 +18,3 @@ pub fn to_vec(hex: &str) -> Option<Vec<u8>> {
 
     Some(out)
 }
-
-pub fn to_compressed_pubkey(hex: &str) -> Option<PublicKey> {
-    let data = match to_vec(&hex[0..33 * 2]) {
-        Some(bytes) => bytes,
-        None => return None,
-    };
-    match PublicKey::from_slice(&data) {
-        Ok(pk) => Some(pk),
-        Err(_) => None,
-    }
-}