Skip to content

Commit 2cf0746

Browse files
committed
πŸ› fix frontend type-check
1 parent dce8613 commit 2cf0746

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

β€Žfrontend/app/[locale]/setup/agents/config.tsxβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ export default function AgentConfig() {
9898
{
9999
agent_id: Number(currentAgentId),
100100
task_description: businessLogic,
101-
model_id: selectedModel?.id || "",
101+
model_id: selectedModel?.id?.toString() || "",
102102
},
103103
(data) => {
104104
// Process streaming response data

β€Žfrontend/app/[locale]/setup/models/components/model/ModelDeleteDialog.tsxβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -448,7 +448,7 @@ export const ModelDeleteDialog = ({
448448
currentIds.has(m.name)
449449
)
450450
.map((m) => ({
451-
model_id: m.id,
451+
model_id: String(m.id),
452452
apiKey: apiKey || m.apiKey,
453453
maxTokens: maxTokens || m.maxTokens,
454454
}));

β€Žfrontend/app/[locale]/setup/models/components/model/ModelEditDialog.tsxβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,7 @@ export const ModelEditDialog = ({ isOpen, model, onClose, onSuccess }: ModelEdit
124124
if (isEmbeddingModel) maxTokensValue = 0
125125

126126
await modelService.updateSingleModel({
127-
model_id: model.id, // Use model name as ID
127+
model_id: model.id.toString(),
128128
displayName: form.displayName,
129129
url: form.url,
130130
apiKey: form.apiKey.trim() === "" ? "sk-no-api-key" : form.apiKey,

0 commit comments

Comments
Β (0)