From c722e97f076f4a5380f41273ed93ec9424b845e5 Mon Sep 17 00:00:00 2001 From: Him188 Date: Mon, 6 Apr 2020 20:33:09 +0800 Subject: [PATCH] Fix StackOverflowError --- .../commonMain/kotlin/net.mamoe.mirai/message/data/builder.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/data/builder.kt b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/data/builder.kt index bd540c4e1..cbb84720f 100644 --- a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/data/builder.kt +++ b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/message/data/builder.kt @@ -67,7 +67,7 @@ class MessageChainBuilder private constructor( if (index != -1) { container[index] = element } else { - add(element) + container.add(element) } return true