Commit 83d4375d authored by jiahua.liu's avatar jiahua.liu

to merge

parent 3844ef33
......@@ -482,7 +482,9 @@ object MiraiConsoleTerminalUI : MiraiConsoleUI {
val width = terminal.terminalSize.columns - 6
var x = string
while (true) {
if (x == "") break
if (x == "") {
break
}
val toWrite = if (x.actualLength() > width) {
val index = x.getSubStringIndexByActualLength(width)
x.substring(0, index).also {
......
......@@ -300,7 +300,7 @@ object MiraiConsole {
if (allDown) {
return
}
var fullCommand = commandChannel.poll()
var fullCommand = commandChannel.take(1)[0]
if (fullCommand != null) {
if (!fullCommand.startsWith("/")) {
fullCommand = "/$fullCommand"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment