From 767e3bbe36ce1fba2e928faa068425f11eead5ef Mon Sep 17 00:00:00 2001 From: ryoii Date: Sun, 23 Feb 2020 15:45:01 +0800 Subject: [PATCH] Graphic console fix command --- .../graphical/controller/MiraiGraphicalUIController.kt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mirai-console-graphical/src/main/kotlin/net/mamoe/mirai/console/graphical/controller/MiraiGraphicalUIController.kt b/mirai-console-graphical/src/main/kotlin/net/mamoe/mirai/console/graphical/controller/MiraiGraphicalUIController.kt index 398b1471e..676fc8b5a 100644 --- a/mirai-console-graphical/src/main/kotlin/net/mamoe/mirai/console/graphical/controller/MiraiGraphicalUIController.kt +++ b/mirai-console-graphical/src/main/kotlin/net/mamoe/mirai/console/graphical/controller/MiraiGraphicalUIController.kt @@ -32,11 +32,11 @@ class MiraiGraphicalUIController : Controller(), MiraiConsoleUI { val consoleInfo = ConsoleInfo() - suspend fun login(qq: String, psd: String) { -// MiraiConsole + fun login(qq: String, psd: String) { + MiraiConsole.CommandProcessor.runConsoleCommandBlocking("/login $qq $psd") } - suspend fun sendCommand(command: String) = Unit + fun sendCommand(command: String) = MiraiConsole.CommandProcessor.runConsoleCommandBlocking(command) override fun pushLog(identity: Long, message: String) = Platform.runLater { when (identity) {