fix(opencode): add null checks for agent.current() in prompt#7920
fix(opencode): add null checks for agent.current() in prompt#7920tdawe1 wants to merge 1 commit intoanomalyco:devfrom
Conversation
|
The following comment was made by an LLM, it may be inaccurate: Potential Duplicate PRs FoundI found 2 related PRs that may be addressing the same issue:
Both of these PRs appear to be tackling the same null safety issue for |
00637c0 to
71e0ba2
Compare
f1ae801 to
08fa7f7
Compare
|
Closing this pull request because it has had no updates for more than 60 days. If you plan to continue working on it, feel free to reopen or open a new PR. |
Fixes #7918
What does this PR do?
Adds null safety checks for
local.agent.current()across the TUI codebase.local.agent.current()can returnundefinedwhen:opencode-antigravity-auth) trigger before agent initializationThis caused
TypeError: undefined is not an objectcrashes.Files changed:
All use optional chaining (
?.) with fallback to"default".How did you verify your code works?
./packages/opencode/script/build.ts --singleopencode-antigravity-authplugin enabled