diff options
author | metamuffin <metamuffin@disroot.org> | 2024-06-10 15:28:36 +0200 |
---|---|---|
committer | metamuffin <metamuffin@disroot.org> | 2024-06-10 15:28:36 +0200 |
commit | 05d11426a8e60fa060733eb8ae7843bc2ae9725c (patch) | |
tree | 57cfad9cedf1eb50de193f1657b42234745c044e /base/src/assetfed.rs | |
parent | c0365c8c64f403fd9ee75c0db1a9ed6134633e8f (diff) | |
download | jellything-05d11426a8e60fa060733eb8ae7843bc2ae9725c.tar jellything-05d11426a8e60fa060733eb8ae7843bc2ae9725c.tar.bz2 jellything-05d11426a8e60fa060733eb8ae7843bc2ae9725c.tar.zst |
apply many clippy issue
Diffstat (limited to 'base/src/assetfed.rs')
-rw-r--r-- | base/src/assetfed.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/base/src/assetfed.rs b/base/src/assetfed.rs index 4ca587b..bb39bbd 100644 --- a/base/src/assetfed.rs +++ b/base/src/assetfed.rs @@ -38,7 +38,7 @@ impl AssetInner { pub fn ser(&self) -> Asset { let mut plaintext = Vec::new(); plaintext.extend(u32::to_le_bytes(VERSION)); - plaintext.extend(bincode::encode_to_vec(&self, bincode::config::standard()).unwrap()); + plaintext.extend(bincode::encode_to_vec(self, bincode::config::standard()).unwrap()); while plaintext.len() % 16 == 0 { plaintext.push(0); @@ -53,7 +53,7 @@ impl AssetInner { Asset(base64::engine::general_purpose::URL_SAFE.encode(&ciphertext)) } pub fn deser(s: &str) -> anyhow::Result<Self> { - let ciphertext = base64::engine::general_purpose::URL_SAFE.decode(&s)?; + let ciphertext = base64::engine::general_purpose::URL_SAFE.decode(s)?; let (ciphertext, nonce) = ciphertext.split_at(ciphertext.len() - 12); let plaintext = ASSET_KEY .decrypt(nonce.into(), ciphertext) |