fix: error throw
This commit is contained in:
1 parent
5632488d15
commit
73d89c675b
11 files changed
+27
-29
No files matched your search
@@ -30,7 +30,7 @@ class MarkMsgAsRead extends BaseAction<PlayloadType, null> {
|
||||
if (payload.user_id) {
|
||||
const peerUid = await this.core.apis.UserApi.getUidByUinV2(payload.user_id.toString());
|
||||
if (!peerUid) {
|
||||
throw `私聊${payload.user_id}不存在`;
|
||||
throw new Error( `私聊${payload.user_id}不存在`);
|
||||
}
|
||||
const isBuddy = await this.core.apis.FriendApi.isBuddy(peerUid);
|
||||
return { chatType: isBuddy ? ChatType.KCHATTYPEC2C : ChatType.KCHATTYPETEMPC2CFROMGROUP, peerUid };
|
||||
|
||||
Reference in new issue
Block a user