core: prevent crash when starting in repositories without any commits yet
This commit is contained in:
parent
98be75b17c
commit
85f15893bc
1 changed files with 1 additions and 1 deletions
|
|
@ -60,7 +60,7 @@ export namespace Project {
|
||||||
.toSorted(),
|
.toSorted(),
|
||||||
)
|
)
|
||||||
id = roots[0]
|
id = roots[0]
|
||||||
Bun.file(path.join(git, "opencode")).write(id)
|
if (id) Bun.file(path.join(git, "opencode")).write(id)
|
||||||
}
|
}
|
||||||
timer.stop()
|
timer.stop()
|
||||||
if (!id) {
|
if (!id) {
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue