diff options
| author | Burak Yigit Kaya <[email protected]> | 2026-03-24 14:01:58 +0000 |
|---|---|---|
| committer | GitHub <[email protected]> | 2026-03-24 09:01:58 -0500 |
| commit | 3f1a4abe6dc72b4d24b916436d3dd95393aeb650 (patch) | |
| tree | 52284da192b02efe7dfe332d547fd4e44c4c42e4 /packages/app/src/components | |
| parent | 431e0586add85c108ceadc0366a08ee09b862ecc (diff) | |
| download | opencode-3f1a4abe6dc72b4d24b916436d3dd95393aeb650.tar.gz opencode-3f1a4abe6dc72b4d24b916436d3dd95393aeb650.zip | |
fix(app): use optional chaining for model.current() in ProviderIcon (#18927)
Diffstat (limited to 'packages/app/src/components')
| -rw-r--r-- | packages/app/src/components/prompt-input.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/packages/app/src/components/prompt-input.tsx b/packages/app/src/components/prompt-input.tsx index 34f83b13e..f523671ec 100644 --- a/packages/app/src/components/prompt-input.tsx +++ b/packages/app/src/components/prompt-input.tsx @@ -1497,7 +1497,7 @@ export const PromptInput: Component<PromptInputProps> = (props) => { > <Show when={local.model.current()?.provider?.id}> <ProviderIcon - id={local.model.current()!.provider.id} + id={local.model.current()?.provider?.id ?? ""} class="size-4 shrink-0 opacity-40 group-hover:opacity-100 transition-opacity duration-150" style={{ "will-change": "opacity", transform: "translateZ(0)" }} /> @@ -1529,7 +1529,7 @@ export const PromptInput: Component<PromptInputProps> = (props) => { > <Show when={local.model.current()?.provider?.id}> <ProviderIcon - id={local.model.current()!.provider.id} + id={local.model.current()?.provider?.id ?? ""} class="size-4 shrink-0 opacity-40 group-hover:opacity-100 transition-opacity duration-150" style={{ "will-change": "opacity", transform: "translateZ(0)" }} /> |
