diff --git a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/BotImpl.kt b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/BotImpl.kt index 7f958fd05..537465380 100644 --- a/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/BotImpl.kt +++ b/mirai-core/src/commonMain/kotlin/net.mamoe.mirai/BotImpl.kt @@ -13,6 +13,7 @@ import kotlin.coroutines.CoroutineContext /* * 泛型 N 不需要向外(接口)暴露. */ +@UseExperimental(MiraiExperimentalAPI::class) @MiraiInternalAPI abstract class BotImpl constructor( account: BotAccount, @@ -25,8 +26,7 @@ abstract class BotImpl constructor( @Suppress("CanBePrimaryConstructorProperty") // for logger final override val account: BotAccount = account - @UseExperimental(MiraiExperimentalAPI::class) - final override val uin: Long + override val uin: Long get() = account.id final override val logger: MiraiLogger = configuration.logger ?: DefaultLogger("Bot($uin)").also { configuration.logger = it }