summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNeal H. Walfield <neal@pep.foundation>2023-05-12 12:11:57 +0200
committerNeal H. Walfield <neal@pep.foundation>2023-05-12 13:28:23 +0200
commitabf2d1060c906522fa48985c488f015cd6bc3097 (patch)
tree99aa2db861d52a83b5c94d5b0596fc09628ae310
parentf910aa90dfa15e5d3b842047dee89cd0a14379b4 (diff)
autocrypt: Don't use a callback where a constant will do.
- `str::splitn` takes a callback or a `char`. Since we are just splitting on a `char`, pass it directly.
-rw-r--r--autocrypt/src/lib.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/autocrypt/src/lib.rs b/autocrypt/src/lib.rs
index f8d23420..7412214c 100644
--- a/autocrypt/src/lib.rs
+++ b/autocrypt/src/lib.rs
@@ -297,7 +297,7 @@ impl AutocryptHeaders {
for pair in ac_value.split(';') {
let pair = pair
- .splitn(2, |c| c == '=')
+ .splitn(2, '=')
.collect::<Vec<&str>>();
let (key, value) : (String, String) = if pair.len() == 1 {