pub fn try_resolve_lineage<'b>(
        &self,
        storage: &'b dyn Storage,
        lineage: &String,
    ) -> Result<NameRecord> {
        match base32::decode(
            base32::Alphabet::RFC4648 { padding: false },
            lineage.as_str(),
        ) {
            Some(lineage_bytes) => self
                .get_lineage(storage)
                .load(lineage_bytes.as_slice())
                .context(format!(
                    "Could not find lineage {} in .{}",
                    lineage, self.tld
                )),
            None => Err(anyhow!("Unable to decode specified lineage as base32")),
        }
    }
/// Attempt to lookup a lineage given a lineage hash
/// Will return an Err if the lineage is not found
Attempt to lookup a lineage given a lineage hash
Will return an Err if the lineage is not found
Attempt to lookup a lineage given a lineage hash Will return an Err if the lineage is not found
pub fn try_resolve_lineage<'b>(
        &self,
        storage: &'b dyn Storage,
        lineage: &String,
    ) -> Result<NameRecord> {
        match base32::decode(
            base32::Alphabet::RFC4648 { padding: false },
            lineage.as_str(),
        ) {
            Some(lineage_bytes) => self
                .get_lineage(storage)
                .load(lineage_bytes.as_slice())
                .context(format!(
                    "Could not find lineage {} in .{}",
                    lineage, self.tld
                )),
            None => Err(anyhow!("Unable to decode specified lineage as base32")),
        }
    }
pub fn try_resolve_lineage < ' b > ( & self , storage : & ' b dyn Storage , lineage : & String , ) -> Result < NameRecord > { match base32 :: decode ( base32 :: Alphabet :: RFC4648 { padding : false } , lineage . as_str ( ) , ) { Some ( lineage_bytes ) => self . get_lineage ( storage ) . load ( lineage_bytes . as_slice ( ) ) . context ( format ! ( " " lineage self tld ) ) , None => Err ( anyhow ! ( " " ) ) , } }
Attempt to lookup a lineage given a lineage hash
Will return an Err if the lineage is not found
Attempt to lookup a lineage given a lineage hash Will return an Err if the lineage is not found
&self
storage
&'b dyn Storage
lineage
&String
&self
storage
&'b dyn Storage
lineage
&String