From 3da76125a63a993ce6f3cd35071db34782a70574 Mon Sep 17 00:00:00 2001 From: Him188 Date: Wed, 6 Jan 2021 15:17:14 +0800 Subject: [PATCH] [Review] Stable Stranger.nudge --- mirai-core-api/src/commonMain/kotlin/contact/Stranger.kt | 4 +--- mirai-core-api/src/commonMain/kotlin/message/action/Nudge.kt | 4 ++-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/mirai-core-api/src/commonMain/kotlin/contact/Stranger.kt b/mirai-core-api/src/commonMain/kotlin/contact/Stranger.kt index b9486faa5..1adc68253 100644 --- a/mirai-core-api/src/commonMain/kotlin/contact/Stranger.kt +++ b/mirai-core-api/src/commonMain/kotlin/contact/Stranger.kt @@ -1,5 +1,5 @@ /* - * Copyright 2019-2020 Mamoe Technologies and contributors. + * Copyright 2019-2021 Mamoe Technologies and contributors. * * 此源代码的使用受 GNU AFFERO GENERAL PUBLIC LICENSE version 3 许可证的约束, 可以在以下链接找到该许可证. * Use of this source code is governed by the GNU AGPLv3 license that can be found through the following link. @@ -21,7 +21,6 @@ import net.mamoe.mirai.message.action.StrangerNudge import net.mamoe.mirai.message.data.Message import net.mamoe.mirai.message.data.isContentEmpty import net.mamoe.mirai.message.data.toPlainText -import net.mamoe.mirai.utils.MiraiExperimentalApi /** * 代表一位陌生人. @@ -91,6 +90,5 @@ public interface Stranger : User, CoroutineScope { * * @see Nudge.sendTo 发送这个戳一戳消息 */ - @MiraiExperimentalApi public override fun nudge(): StrangerNudge = StrangerNudge(this) } \ No newline at end of file diff --git a/mirai-core-api/src/commonMain/kotlin/message/action/Nudge.kt b/mirai-core-api/src/commonMain/kotlin/message/action/Nudge.kt index c8413ed17..23c5e6689 100644 --- a/mirai-core-api/src/commonMain/kotlin/message/action/Nudge.kt +++ b/mirai-core-api/src/commonMain/kotlin/message/action/Nudge.kt @@ -1,5 +1,5 @@ /* - * Copyright 2019-2020 Mamoe Technologies and contributors. + * Copyright 2019-2021 Mamoe Technologies and contributors. * * 此源代码的使用受 GNU AFFERO GENERAL PUBLIC LICENSE version 3 许可证的约束, 可以在以下链接找到该许可证. * Use of this source code is governed by the GNU AGPLv3 license that can be found through the following link. @@ -106,5 +106,5 @@ public data class FriendNudge( * @see Nudge */ public data class StrangerNudge( - public override val target: UserOrBot + public override val target: Stranger ) : UserNudge() \ No newline at end of file