release the lock when there are broken projects

This commit is contained in:
Kiril Videlov 2023-03-07 10:18:56 +01:00
parent 96e4f16703
commit efc07705e4

View File

@ -551,8 +551,7 @@ fn init(app_handle: tauri::AppHandle) -> Result<()> {
.lock()
.unwrap()
.reindex_project(&repo, &project)
.with_context(|| format!("Failed to reindex project: {}", project.id))
.unwrap();
.with_context(|| format!("Failed to reindex project: {}", project.id))?;
}
watch_events(app_handle, rx);