wechaty-web-panel 1.6.122 → 1.6.123
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -28,7 +28,7 @@ async function checkAllow(clawConfig, contactId, roomId) {
|
|
|
28
28
|
else if (allowScope === 4) {
|
|
29
29
|
// 部分群和部分好友
|
|
30
30
|
if (roomId) {
|
|
31
|
-
return allowRooms.some(r => r.
|
|
31
|
+
return allowRooms.some(r => r.id === roomId);
|
|
32
32
|
}
|
|
33
33
|
else {
|
|
34
34
|
return allowFriends.some(f => f.id === contactId);
|
|
@@ -208,6 +208,10 @@ async function onClawMessage(msg) {
|
|
|
208
208
|
else {
|
|
209
209
|
if (!forwardMediaMsg)
|
|
210
210
|
return;
|
|
211
|
+
// 媒体消息无法 @,若 forwardMediaMsg 开启且在允许的群中,视为已提及,避免被 requireMention 拦截
|
|
212
|
+
if (room) {
|
|
213
|
+
baseMsg.isMention = true;
|
|
214
|
+
}
|
|
211
215
|
}
|
|
212
216
|
publishClawMessage(baseMsg, robotInfo);
|
|
213
217
|
}
|
package/dist/package-json.js
CHANGED
package/package.json
CHANGED
|
@@ -28,7 +28,7 @@ async function checkAllow(clawConfig, contactId, roomId) {
|
|
|
28
28
|
} else if (allowScope === 4) {
|
|
29
29
|
// 部分群和部分好友
|
|
30
30
|
if (roomId) {
|
|
31
|
-
return allowRooms.some(r => r.
|
|
31
|
+
return allowRooms.some(r => r.id === roomId)
|
|
32
32
|
} else {
|
|
33
33
|
return allowFriends.some(f => f.id === contactId)
|
|
34
34
|
}
|
|
@@ -203,6 +203,10 @@ async function onClawMessage(msg) {
|
|
|
203
203
|
}
|
|
204
204
|
} else {
|
|
205
205
|
if (!forwardMediaMsg) return
|
|
206
|
+
// 媒体消息无法 @,若 forwardMediaMsg 开启且在允许的群中,视为已提及,避免被 requireMention 拦截
|
|
207
|
+
if (room) {
|
|
208
|
+
baseMsg.isMention = true
|
|
209
|
+
}
|
|
206
210
|
}
|
|
207
211
|
publishClawMessage(baseMsg, robotInfo)
|
|
208
212
|
} catch (e) {
|