mirror of
https://github.com/chatmail/core.git
synced 2026-04-17 21:46:35 +03:00
Fix trim_split_whitespace clippy lint
This commit is contained in:
@@ -40,7 +40,7 @@ pub trait DcKey: Serialize + Deserializable + KeyTrait + Clone {
|
||||
/// Create a key from a base64 string.
|
||||
fn from_base64(data: &str) -> Result<Self::KeyType> {
|
||||
// strip newlines and other whitespace
|
||||
let cleaned: String = data.trim().split_whitespace().collect();
|
||||
let cleaned: String = data.split_whitespace().collect();
|
||||
let bytes = base64::decode(cleaned.as_bytes())?;
|
||||
Self::from_slice(&bytes)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user