diff --git a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/BotHelper.kt b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/BotHelper.kt index acfc697fb..9cee23109 100644 --- a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/BotHelper.kt +++ b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/BotHelper.kt @@ -91,7 +91,7 @@ suspend inline fun Bot.alsoLogin(): Bot = apply { login().requireSuccess() } * 使用在默认配置基础上修改的配置进行登录, 返回 [this] */ @UseExperimental(ExperimentalContracts::class) -suspend inline fun Bot.alsoLogin(noinline configuration: BotConfiguration.() -> Unit): Bot { +suspend inline fun Bot.alsoLogin(configuration: BotConfiguration.() -> Unit): Bot { contract { callsInPlace(configuration, InvocationKind.EXACTLY_ONCE) }