mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2024-11-21 09:36:35 +00:00
feat: 拦截不合法消息
This commit is contained in:
parent
91b794d66d
commit
0dbfe8ca55
@ -421,6 +421,10 @@ export class OneBotMsgApi {
|
|||||||
// 从face_config.json中获取表情名称
|
// 从face_config.json中获取表情名称
|
||||||
const sysFaces = faceConfig.sysface;
|
const sysFaces = faceConfig.sysface;
|
||||||
const face: any = sysFaces.find((systemFace) => systemFace.QSid === parsedFaceId.toString());
|
const face: any = sysFaces.find((systemFace) => systemFace.QSid === parsedFaceId.toString());
|
||||||
|
if (!face) {
|
||||||
|
this.core.context.logger.logError('不支持的ID', id);
|
||||||
|
return undefined;
|
||||||
|
}
|
||||||
parsedFaceId = parseInt(parsedFaceId.toString());
|
parsedFaceId = parseInt(parsedFaceId.toString());
|
||||||
let faceType = 1;
|
let faceType = 1;
|
||||||
if (parsedFaceId >= 222) {
|
if (parsedFaceId >= 222) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user