From 28cab02afe3c19bb921c565ecb2164156e1f1616 Mon Sep 17 00:00:00 2001 From: sghpjuikit Date: Sun, 19 Jan 2025 20:03:54 +0000 Subject: [PATCH] Fix missing arg in logging output --- src/player/main/sp/it/pl/main/AppInstanceCom.kt | 4 ++-- src/util/main/sp/it/util/file/json/JsonParsing.kt | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/player/main/sp/it/pl/main/AppInstanceCom.kt b/src/player/main/sp/it/pl/main/AppInstanceCom.kt index 55b3510cd..25c26e4c1 100644 --- a/src/player/main/sp/it/pl/main/AppInstanceCom.kt +++ b/src/player/main/sp/it/pl/main/AppInstanceCom.kt @@ -30,13 +30,13 @@ class AppInstanceCom() { @Blocking fun fireNewInstanceEvent(args: List): Unit = runBlocking(NEW) { - logger.info { "Sending NewAppInstance($args)" } + logger.info { "Sending NewAppInstance(args=$args)" } APP.http.client.post("http://127.0.0.1:${APP.http.url.port}$api") { bodyJs(args) } } /** Handles received new app instance event */ fun newInstanceLaunched(args: List) { - logger.info { "NewAppInstance($args)" } + logger.info { "NewAppInstance(args=$args)" } runFX { onNewInstanceHandlers(args) } } diff --git a/src/util/main/sp/it/util/file/json/JsonParsing.kt b/src/util/main/sp/it/util/file/json/JsonParsing.kt index 465a62096..b16164aca 100644 --- a/src/util/main/sp/it/util/file/json/JsonParsing.kt +++ b/src/util/main/sp/it/util/file/json/JsonParsing.kt @@ -288,7 +288,7 @@ private class Parser(lexer: Lexer) { is Num -> return JsNumber(token.value) Lbk -> JsArrayParseState(ArrayList()).apply { stack.push(c) } Lbc -> JsObjectParseState(LinkedHashMap()).apply { stack.push(c) } - else -> fail { "Invalid token at position $lexerLastPos" } + else -> fail { "Invalid token=$token at position $lexerLastPos" } } is JsArrayParseState -> when (val token = currentToken.apply { consumeToken(currentToken) }) { @@ -306,7 +306,7 @@ private class Parser(lexer: Lexer) { stack.pop() } ?: x } - else -> fail { "Invalid token at position $lexerLastPos" } + else -> fail { "Invalid token=$token at position $lexerLastPos" } } is JsObjectParseState -> when (val token = currentToken.apply { consumeToken(currentToken) }) { @@ -321,7 +321,7 @@ private class Parser(lexer: Lexer) { stack.pop() } ?: x } - else -> fail { "Invalid token at position $lexerLastPos" } + else -> fail { "Invalid token=$token at position $lexerLastPos" } } is JsObjectKeyParseState -> when (val token = currentToken.apply { consumeToken(currentToken) }) { @@ -333,7 +333,7 @@ private class Parser(lexer: Lexer) { Lbk -> JsArrayParseState(ArrayList()).apply { stack.push(c) } Lbc -> JsObjectParseState(LinkedHashMap()).apply { stack.push(c) } Rbc -> { stack.pop().apply { c.o.value.put(c.key, c.value.asIs()) }.com(); stack.pop().apply { add(JsObject(c.o.value)) } } - else -> fail { "Invalid token at position $lexerLastPos" } + else -> fail { "Invalid token=$token at position $lexerLastPos" } } } } while (