diff --git a/src/components/chatui.vue b/src/components/chatui.vue index e1ef0b1..71b1049 100644 --- a/src/components/chatui.vue +++ b/src/components/chatui.vue @@ -95,6 +95,7 @@ async function getFileInfo(code) { async function downloadFile(code) { if (fileInfoCache.value[code].status === 'waittingDownload') { + fileInfoCache.value[code].status = `downloading`; return new Promise((resolve, reject) => { let id = code.substring(0, 8); let key = code.substring(8); @@ -227,7 +228,7 @@ const fileInfoCache = ref({}) const fileStatus2String = ref({ waittingDownload: '点击下载', downloading: '下载中', - finish: '点击获取', + finish: '下载完成', Unknow: '获取文件信息中', error: '出错' }) diff --git a/src/views/chat.vue b/src/views/chat.vue index 2f909c9..449af50 100644 --- a/src/views/chat.vue +++ b/src/views/chat.vue @@ -283,7 +283,7 @@ function joinGroup_Verify(gID) { } function sendMsg(gID, msg) { - if(msg === '' || activeGID.value === null)return + if(msg === '' || msg === null || activeGID.value === null)return let key = gID2key[gID].key msg = encryptString(key, msg, setting) socket.send(JSON.stringify({ type: 'message',type1:'text', msg, gID })) diff --git a/vite.config.js b/vite.config.js index f6ff2bf..4953b3a 100644 --- a/vite.config.js +++ b/vite.config.js @@ -18,4 +18,7 @@ export default defineConfig({ port:'17058', open:true, }, + esbuild: { + drop: ['console', 'debugger'], + }, }) \ No newline at end of file