small fix
This commit is contained in:
parent
79476f66a6
commit
1b3aa629da
@ -115,6 +115,8 @@ const Configs: FC = observer(() => {
|
||||
|
||||
const onClickSave = () => {
|
||||
commonStore.setModelConfig(selectedIndex, selectedConfig);
|
||||
const webgpu = selectedConfig.modelParameters.device === 'WebGPU';
|
||||
if (!webgpu) {
|
||||
// When clicking RunButton in Configs page, updateConfig will be called twice,
|
||||
// because there are also RunButton in other pages, and the calls to updateConfig in both places are necessary.
|
||||
updateConfig({
|
||||
@ -137,6 +139,7 @@ const Configs: FC = observer(() => {
|
||||
toast(error, { type: 'error' });
|
||||
}
|
||||
});
|
||||
}
|
||||
toast(t('Config Saved'), { autoClose: 300, type: 'success' });
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user