diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/test/TestExportTools.kt | 3 | ||||
-rw-r--r-- | src/main/java/at/hannibal2/skyhanni/test/command/ErrorManager.kt | 4 |
2 files changed, 3 insertions, 4 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/test/TestExportTools.kt b/src/main/java/at/hannibal2/skyhanni/test/TestExportTools.kt index 6b4362215..b7c1a6f4b 100644 --- a/src/main/java/at/hannibal2/skyhanni/test/TestExportTools.kt +++ b/src/main/java/at/hannibal2/skyhanni/test/TestExportTools.kt @@ -40,7 +40,7 @@ object TestExportTools { val data: JsonElement, ) - fun <T> toJson(key: Key<T>, value: T): String { + private fun <T> toJson(key: Key<T>, value: T): String { return gson.toJson(TestValue(key.name, gson.toJsonTree(value))) } @@ -64,7 +64,6 @@ object TestExportTools { LorenzUtils.chat("Compressed item info copied into the clipboard!") } - inline fun <reified T> getTestData(category: Key<T>, name: String): T { val reader = InputStreamReader(javaClass.getResourceAsStream("/testdata/${category.name}/$name.json")!!) return fromJson(category, reader) diff --git a/src/main/java/at/hannibal2/skyhanni/test/command/ErrorManager.kt b/src/main/java/at/hannibal2/skyhanni/test/command/ErrorManager.kt index 277452f5a..0e7bccab6 100644 --- a/src/main/java/at/hannibal2/skyhanni/test/command/ErrorManager.kt +++ b/src/main/java/at/hannibal2/skyhanni/test/command/ErrorManager.kt @@ -40,8 +40,8 @@ object ErrorManager { } else { errorMessages[id] } - val name = if (fullErrorMessage) "Ful error" else "Error" - LorenzUtils.userError(errorMessage?.let { + val name = if (fullErrorMessage) "Full error" else "Error" + LorenzUtils.chat(errorMessage?.let { OSUtils.copyToClipboard(it) "$name copied into the clipboard, please report it on the SkyHanni discord!" } ?: "Error id not found!") |