fix(logging): log errors instead of silently discarding with .ok()

Replace silent .ok() calls with explicit match + warn! logging in
encode_quick_notes and passkey deserialization for exclude lists.
This commit is contained in:
Jon Seager 2026-02-06 18:19:24 +00:00
parent 3594ad40ea
commit b5fdf8b27c
No known key found for this signature in database

View file

@ -68,7 +68,13 @@ impl SqlBrewRepository {
None None
} else { } else {
let labels: Vec<&str> = notes.iter().map(|n| n.label()).collect(); let labels: Vec<&str> = notes.iter().map(|n| n.label()).collect();
serde_json::to_string(&labels).ok() match serde_json::to_string(&labels) {
Ok(json) => Some(json),
Err(err) => {
tracing::warn!(error = %err, "failed to encode quick notes as JSON");
None
}
}
} }
} }