Skip to content

Commit 0879bcd

Browse files
committed
Remove unused env property for ApiOptions
Signed-off-by: Geoff Wilson <[email protected]>
1 parent 08e7d73 commit 0879bcd

File tree

3 files changed

+1
-6
lines changed

3 files changed

+1
-6
lines changed

webview-ui/src/components/settings/ApiOptions.tsx

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,6 @@ export interface ApiOptionsProps {
109109
fromWelcomeView?: boolean
110110
errorMessage: string | undefined
111111
setErrorMessage: React.Dispatch<React.SetStateAction<string | undefined>>
112-
env?: Record<string, string | undefined>
113112
}
114113

115114
const ApiOptions = ({
@@ -119,7 +118,6 @@ const ApiOptions = ({
119118
fromWelcomeView,
120119
errorMessage,
121120
setErrorMessage,
122-
env: _env = {}
123121
}: ApiOptionsProps) => {
124122
const { t } = useAppTranslation()
125123
const { organizationAllowList } = useExtensionState()
@@ -448,7 +446,7 @@ const ApiOptions = ({
448446
)}
449447

450448
{selectedProvider === "anthropic" && (
451-
<Anthropic apiConfiguration={apiConfiguration} setApiConfigurationField={setApiConfigurationField}/>
449+
<Anthropic apiConfiguration={apiConfiguration} setApiConfigurationField={setApiConfigurationField} />
452450
)}
453451

454452
{selectedProvider === "claude-code" && (

webview-ui/src/components/settings/SettingsView.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,6 @@ const SettingsView = forwardRef<SettingsViewRef, SettingsViewProps>(({ onDone, t
118118
const confirmDialogHandler = useRef<() => void>()
119119

120120
const [cachedState, setCachedState] = useState(extensionState)
121-
const [env, _] = useState<Record<string, string | undefined>>({})
122121

123122
const {
124123
alwaysAllowReadOnly,
@@ -606,7 +605,6 @@ const SettingsView = forwardRef<SettingsViewRef, SettingsViewProps>(({ onDone, t
606605
setApiConfigurationField={setApiConfigurationField}
607606
errorMessage={errorMessage}
608607
setErrorMessage={setErrorMessage}
609-
env={env}
610608
/>
611609
</Section>
612610
</div>

webview-ui/src/components/settings/__tests__/ApiOptions.spec.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -276,7 +276,6 @@ const renderApiOptions = (props: Partial<ApiOptionsProps> = {}) => {
276276
uriScheme={undefined}
277277
apiConfiguration={{}}
278278
setApiConfigurationField={() => {}}
279-
env={{}} // Mock environment variables
280279
{...props}
281280
/>
282281
</QueryClientProvider>

0 commit comments

Comments
 (0)