From b01584c49e235b79c6ed3898fd2892b06577eca2 Mon Sep 17 00:00:00 2001 From: josc146 Date: Sat, 3 Jun 2023 00:10:31 +0800 Subject: [PATCH] chore --- frontend/src/components/RunButton.tsx | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/frontend/src/components/RunButton.tsx b/frontend/src/components/RunButton.tsx index c414d8c..dd6ac67 100644 --- a/frontend/src/components/RunButton.tsx +++ b/frontend/src/components/RunButton.tsx @@ -179,7 +179,10 @@ export const RunButton: FC<{ onClickRun?: MouseEventHandler, iconMode?: boolean } }).catch(() => { commonStore.setStatus({ status: ModelStatus.Offline }); - toast(t('Failed to switch model, please try starting the program with administrator privileges.'), { type: 'error' }); + if (commonStore.platform === 'windows') + toast(t('Failed to switch model, please try starting the program with administrator privileges.'), { type: 'error' }); + else + toast(t('Failed to switch model'), { type: 'error' }); }); } }).catch(() => {