Skip to content

Commit 42076ee

Browse files
committed
fix(gui): defer setState in qwen-cloud effect to satisfy lint
1 parent 1231e9a commit 42076ee

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

gui/src/components/provider-workspace/ProviderSettings.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ export default function ProviderSettings({
5353
setNote(item.note ?? "");
5454
setAllowPrivateNetwork(item.allowPrivateNetwork ?? false);
5555
setMsg(null);
56-
setEndpointChoice(matchChoiceId(baseUrlChoices, item.baseUrl));
56+
queueMicrotask(() => setEndpointChoice(matchChoiceId(baseUrlChoices, item.baseUrl)));
5757
}, [item.adapter, item.baseUrl, item.defaultModel, item.authMode, item.keyOptional, item.note, item.allowPrivateNetwork, baseUrlChoices]);
5858
/* eslint-enable react-hooks/set-state-in-effect */
5959

0 commit comments

Comments
 (0)