Skip to content

Commit

Permalink
Ensure public keys are public
Browse files Browse the repository at this point in the history
  • Loading branch information
clehner committed Feb 2, 2022
1 parent 9296c28 commit ffada32
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cli/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -543,10 +543,10 @@ impl TryFrom<PublicKeyArgEnum> for PublicKeyProperty {
PublicKeyArgEnum::PublicKeyJwkPath(path) => {
let key_file = File::open(path).context("Open JWK file")?;
let key_reader = BufReader::new(key_file);
let jwk = serde_json::from_reader(key_reader).context("Read JWK file")?;
PublicKeyProperty::JWK(jwk)
let jwk: JWK = serde_json::from_reader(key_reader).context("Read JWK file")?;
PublicKeyProperty::JWK(jwk.to_public())
}
PublicKeyArgEnum::PublicKeyJwk(jwk) => PublicKeyProperty::JWK(jwk),
PublicKeyArgEnum::PublicKeyJwk(jwk) => PublicKeyProperty::JWK(jwk.to_public()),
PublicKeyArgEnum::PublicKeyMultibase(mb) => PublicKeyProperty::Multibase(mb),
PublicKeyArgEnum::BlockchainAccountId(account) => PublicKeyProperty::Account(account),
})
Expand Down

0 comments on commit ffada32

Please sign in to comment.