fix(serde deser): remove needless `len` check
Co-Authored-By: niklasad1 <niklasadolfsson1@gmail.com>
This commit is contained in:
parent
7a6ade2937
commit
a05c677e71
|
@ -81,7 +81,7 @@ pub fn deserialize_check_len<'de, D>(deserializer: D, len: ExpectedLen) -> Resul
|
|||
}
|
||||
|
||||
fn visit_str<E: de::Error>(self, v: &str) -> Result<Self::Value, E> {
|
||||
if v.len() < 2 || !v.starts_with("0x") {
|
||||
if !v.starts_with("0x") {
|
||||
return Err(E::custom("prefix is missing"))
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue