Get rid of rustc_hex in favor of hex (#5370)

* Get rid of rustc_hex in favor of hex

* Use HexDisplay
This commit is contained in:
Stanislav Tkach
2020-03-24 12:48:23 +02:00
committed by GitHub
parent 5345407783
commit 4414d00082
10 changed files with 34 additions and 41 deletions
-1
View File
@@ -16,7 +16,6 @@ sp-runtime = { version = "2.0.0-alpha.4", path = "../../../primitives/runtime" }
rand = "0.7.2"
clap = "2.33.0"
tiny-bip39 = "0.7"
rustc-hex = "2.0.1"
substrate-bip39 = "0.4.1"
hex = "0.4.0"
hex-literal = "0.2.1"
+2 -2
View File
@@ -648,7 +648,7 @@ fn read_pair<C: Crypto>(
}
fn format_signature<C: Crypto>(signature: &SignatureOf<C>) -> String {
format!("{}", hex::encode(signature))
format!("{}", HexDisplay::from(&signature.as_ref()))
}
fn format_seed<C: Crypto>(seed: SeedOf<C>) -> String {
@@ -711,7 +711,7 @@ fn create_extrinsic<C: Crypto>(
}
fn print_extrinsic(extrinsic: UncheckedExtrinsic) {
println!("0x{}", hex::encode(&extrinsic.encode()));
println!("0x{}", HexDisplay::from(&extrinsic.encode()));
}
fn print_usage(matches: &ArgMatches) {