Remove 2x superfluous to_vec
This commit is contained in:
+1
-2
@@ -103,7 +103,7 @@ impl Envelope {
|
|||||||
|
|
||||||
let ciphertext: Vec<u8> = xor_key
|
let ciphertext: Vec<u8> = xor_key
|
||||||
.iter()
|
.iter()
|
||||||
.zip(plaintext.to_vec().iter())
|
.zip(plaintext.iter())
|
||||||
.map(|(&x1, &x2)| x1 ^ x2)
|
.map(|(&x1, &x2)| x1 ^ x2)
|
||||||
.collect();
|
.collect();
|
||||||
|
|
||||||
@@ -143,7 +143,6 @@ impl Envelope {
|
|||||||
}
|
}
|
||||||
|
|
||||||
let plaintext: Vec<u8> = xor_key
|
let plaintext: Vec<u8> = xor_key
|
||||||
.to_vec()
|
|
||||||
.iter()
|
.iter()
|
||||||
.zip(self.ciphertext.iter())
|
.zip(self.ciphertext.iter())
|
||||||
.map(|(&x1, &x2)| x1 ^ x2)
|
.map(|(&x1, &x2)| x1 ^ x2)
|
||||||
|
|||||||
Reference in New Issue
Block a user