community: the encrypted inbox, friend requests and shares travel sealed to a box key when the other side has published one

This commit is contained in:
KeelrLeek committed 2026-09-02 15:26:30 -05:00
1 parent 13c44f731a
commit 4378c4c0cc
14 files changed
+1387 -145

No files matched your search

+16
View File
@@ -293,6 +293,22 @@ pub(crate) fn remember(app: &tauri::AppHandle, link: KnownLink) {
let _ = save(app, &links);
}
/// The Soulseek account a verified persona key belongs to, if this device
/// verified one (our own included).
pub(crate) fn username_for_key(app: &tauri::AppHandle, persona_key: &str) -> Option<String> {
let links = load(app);
if let Some(o) = &links.own {
if o.persona_key == persona_key {
return Some(o.username.clone());
}
}
links
.others
.values()
.find(|l| l.persona_key == persona_key)
.map(|l| l.username.clone())
}
// ---------------------------------------------------------------- commands
#[tauri::command]