fix(core): filter dead worktrees
This commit is contained in:
@@ -272,7 +272,11 @@ export namespace Project {
|
|||||||
|
|
||||||
export async function list() {
|
export async function list() {
|
||||||
const keys = await Storage.list(["project"])
|
const keys = await Storage.list(["project"])
|
||||||
return await Promise.all(keys.map((x) => Storage.read<Info>(x)))
|
const projects = await Promise.all(keys.map((x) => Storage.read<Info>(x)))
|
||||||
|
return projects.map((project) => ({
|
||||||
|
...project,
|
||||||
|
sandboxes: project.sandboxes.filter((x) => existsSync(x)),
|
||||||
|
}))
|
||||||
}
|
}
|
||||||
|
|
||||||
export const update = fn(
|
export const update = fn(
|
||||||
|
|||||||
Reference in New Issue
Block a user