Skip to content

Commit

Permalink
perf: chat init error log
Browse files Browse the repository at this point in the history
  • Loading branch information
c121914yu committed Jul 4, 2024
1 parent f1290bc commit 85895cd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 6 deletions.
5 changes: 0 additions & 5 deletions projects/app/src/pages/chat/share.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,6 @@ const OutLink = ({ appName, appIntro, appAvatar }: Props) => {
authToken: string;
[key: string]: string;
};
const { toast } = useToast();
const { isPc } = useSystemStore();
const ChatBoxRef = useRef<ComponentRef>(null);
const initSign = useRef(false);
Expand Down Expand Up @@ -209,10 +208,6 @@ const OutLink = ({ appName, appIntro, appAvatar }: Props) => {
},
onError(e: any) {
console.log(e);
toast({
status: 'error',
title: getErrText(e, t('core.shareChat.Init Error'))
});
if (chatId) {
onChangeChatId('');
}
Expand Down
3 changes: 2 additions & 1 deletion projects/app/src/web/core/chat/context/chatContext.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,8 @@ const ChatContextProvider = ({
const { runAsync: onUpdateHistory, loading: isUpdatingHistory } = useRequest2(putChatHistory, {
onSuccess() {
loadHistories();
}
},
errorToast: undefined
});
const { runAsync: onDelHistory, loading: isDeletingHistory } = useRequest2(delChatHistoryById, {
onSuccess() {
Expand Down

0 comments on commit 85895cd

Please sign in to comment.