风险提醒优化
This commit is contained in:
@@ -1165,6 +1165,16 @@ NSString * const kHadQuitOtherRoomKey = @"kHadQuitOtherRoomKey";//是否退出
|
||||
if (![message.session.sessionId isEqualToString:[NSString stringWithFormat:@"%ld", self.roomInfo.roomId]]) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (message.yidunAntiSpamRes) {
|
||||
NSDictionary * spamRes = message.yidunAntiSpamRes.toJSONObject;
|
||||
NSDictionary * spamResExt = ((NSString *)spamRes[@"ext"]).toJSONObject;
|
||||
if ([spamResExt[@"antispam"][@"suggestion"] intValue] == 2) {
|
||||
[self showErrorToast:@"消息中可能含有违规信息,请停止发送类似信息!"];
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
if (error) return;
|
||||
if (message.messageType == NIMMessageTypeCustom) {
|
||||
NIMCustomObject *obj = (NIMCustomObject *)message.messageObject;
|
||||
|
Reference in New Issue
Block a user