mirror of
https://github.com/aljazceru/opencode.git
synced 2026-01-05 08:54:55 +01:00
core: prevent crash when starting in repositories without any commits yet
This commit is contained in:
@@ -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) {
|
||||||
|
|||||||
Reference in New Issue
Block a user