Parcourir la source

修复发送消息一直卡住的bug

xsx il y a 5 mois
Parent
commit
9f385eaf6a
2 fichiers modifiés avec 2 ajouts et 2 suppressions
  1. 1 1
      im-uniapp/store/chatStore.js
  2. 1 1
      im-web/src/store/chatStore.js

+ 1 - 1
im-uniapp/store/chatStore.js

@@ -527,7 +527,7 @@ export default defineStore('chatStore', {
 						continue;
 					}
 					if (msgInfo.tmpId == m.tmpId) {
-						return idx;
+						return m;
 					}
 					// 如果id比要查询的消息小,说明没有这条消息
 					if (m.tmpId && m.tmpId < msgInfo.tmpId) {

+ 1 - 1
im-web/src/store/chatStore.js

@@ -555,7 +555,7 @@ export default defineStore('chatStore', {
 						continue;
 					}
 					if (msgInfo.tmpId == m.tmpId) {
-						return idx;
+						return m;
 					}
 					// 如果id比要查询的消息小,说明没有这条消息
 					if (m.tmpId && m.tmpId < msgInfo.tmpId) {