crypto: Remove some unneeded clones.

master
Damir Jelić 2020-08-14 14:29:53 +02:00
parent d21e8213b5
commit 75fa7e97f9
1 changed files with 3 additions and 3 deletions

View File

@ -116,7 +116,7 @@ impl UserIdentity {
master_key: MasterPubkey, master_key: MasterPubkey,
self_signing_key: SelfSigningPubkey, self_signing_key: SelfSigningPubkey,
) -> Result<Self, SignatureError> { ) -> Result<Self, SignatureError> {
master_key.verify_subkey(&self_signing_key.clone())?; master_key.verify_subkey(&self_signing_key)?;
Ok(Self { Ok(Self {
user_id: Arc::new(master_key.0.user_id.clone()), user_id: Arc::new(master_key.0.user_id.clone()),
@ -140,8 +140,8 @@ impl OwnUserIdentity {
self_signing_key: SelfSigningPubkey, self_signing_key: SelfSigningPubkey,
user_signing_key: UserSigningPubkey, user_signing_key: UserSigningPubkey,
) -> Result<Self, SignatureError> { ) -> Result<Self, SignatureError> {
master_key.verify_subkey(&self_signing_key.clone())?; master_key.verify_subkey(&self_signing_key)?;
master_key.verify_subkey(&user_signing_key.clone())?; master_key.verify_subkey(&user_signing_key)?;
Ok(Self { Ok(Self {
user_id: Arc::new(master_key.0.user_id.clone()), user_id: Arc::new(master_key.0.user_id.clone()),