mirror of
https://github.com/zhom/donutbrowser.git
synced 2026-06-10 08:53:58 +02:00
refactor: ui cleanup
This commit is contained in:
@@ -346,6 +346,14 @@ pub fn check_has_e2e_password() -> bool {
|
||||
has_e2e_password()
|
||||
}
|
||||
|
||||
#[tauri::command]
|
||||
pub fn verify_e2e_password(password: String) -> Result<bool, String> {
|
||||
match load_e2e_password()? {
|
||||
Some(stored) => Ok(stored == password),
|
||||
None => Err(serde_json::json!({ "code": "NO_E2E_PASSWORD_SET" }).to_string()),
|
||||
}
|
||||
}
|
||||
|
||||
#[tauri::command]
|
||||
pub async fn delete_e2e_password() -> Result<(), String> {
|
||||
enforce_team_owner_for_encryption_change().await?;
|
||||
|
||||
Reference in New Issue
Block a user