[dependencies]: unify rustc-hex (#11506)
* [dependency]: unify `rustc-hex` * [private tx]: fix upgrade to `rustc hex 2.1.0`
This commit is contained in:
@@ -19,7 +19,7 @@ kvdb = "0.4.0"
|
||||
log = "0.4"
|
||||
parity-bytes = "0.1.0"
|
||||
rlp = "0.4"
|
||||
rustc-hex = "1.0"
|
||||
rustc-hex = "2.1.0"
|
||||
serde = { version = "1.0", features = ["derive"] }
|
||||
trie-db = "0.20.0"
|
||||
triehash = { package = "triehash-ethereum", version = "0.2", path = "../../util/triehash-ethereum" }
|
||||
|
||||
@@ -53,7 +53,7 @@ pub struct PodAccount {
|
||||
fn opt_bytes_to_hex<S>(opt_bytes: &Option<Bytes>, serializer: S) -> Result<S::Ok, S::Error>
|
||||
where S: Serializer
|
||||
{
|
||||
let readable = opt_bytes.as_ref().map(|b| b.to_hex()).unwrap_or_default();
|
||||
let readable: String = opt_bytes.as_ref().map(|b| b.to_hex()).unwrap_or_default();
|
||||
serializer.collect_str(&format_args!("0x{}", readable))
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user