diff --git a/src/components/header/ConversationHeaderShare.tsx b/src/components/header/ConversationHeaderShare.tsx index 02ed567..99d4ab0 100644 --- a/src/components/header/ConversationHeaderShare.tsx +++ b/src/components/header/ConversationHeaderShare.tsx @@ -16,8 +16,7 @@ export default () => { var conversation = currentConversation(); fetchData({id:conversation.id, title: conversation.name }, function(data) { if(data.code==200){ - // window.location.href = data.url; - window.open(data.url) + if (window.open) { window.open(data.url); } else { window.location.href = data.url; } }else{ alert(data.message); }