mirror of
https://github.com/mamoe/mirai.git
synced 2025-03-24 14:30:09 +08:00
Fix ignorance of MultiPacket
using blacklist
This commit is contained in:
parent
84fb928764
commit
271759b4c6
@ -52,14 +52,13 @@ internal class PacketLoggingStrategyImpl(
|
||||
if (packet is ParseErrorPacket) {
|
||||
packet.direction.getLogger(bot).error(packet.error)
|
||||
}
|
||||
if (incomingPacket.commandName in blacklist) return
|
||||
if (incomingPacket.data is MultiPacket<*>) {
|
||||
for (d in incomingPacket.data) {
|
||||
logReceivedImpl(d, incomingPacket, logger)
|
||||
}
|
||||
}
|
||||
if (incomingPacket.commandName !in blacklist) {
|
||||
logReceivedImpl(packet, incomingPacket, logger)
|
||||
}
|
||||
logReceivedImpl(packet, incomingPacket, logger)
|
||||
}
|
||||
|
||||
private fun logReceivedImpl(packet: Packet, incomingPacket: IncomingPacket, logger: MiraiLogger) {
|
||||
|
Loading…
Reference in New Issue
Block a user