aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/test/command
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-06-15 23:19:52 +0200
committerhannibal2 <24389977+hannibal00212@users.noreply.github.com>2023-06-15 23:19:52 +0200
commit04fa4ec7fd514e10f56aedcbe2da4d4f47af9f81 (patch)
tree10c6c0d368071018a0d95c31aba5e36954762942 /src/main/java/at/hannibal2/skyhanni/test/command
parent2ca8d67061d696a199ea07e4d7e85d47a1fec31a (diff)
downloadskyhanni-04fa4ec7fd514e10f56aedcbe2da4d4f47af9f81.tar.gz
skyhanni-04fa4ec7fd514e10f56aedcbe2da4d4f47af9f81.tar.bz2
skyhanni-04fa4ec7fd514e10f56aedcbe2da4d4f47af9f81.zip
Using more exact error message format
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/test/command')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/test/command/CopyErrorCommand.kt9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/test/command/CopyErrorCommand.kt b/src/main/java/at/hannibal2/skyhanni/test/command/CopyErrorCommand.kt
index 6820deba7..c2a35027d 100644
--- a/src/main/java/at/hannibal2/skyhanni/test/command/CopyErrorCommand.kt
+++ b/src/main/java/at/hannibal2/skyhanni/test/command/CopyErrorCommand.kt
@@ -31,13 +31,14 @@ object CopyErrorCommand {
if (cache.getIfPresent(pair) != null) return
cache.put(pair, Unit)
- val errorMessage = error.toString()
- val stackTrace = error.stackTrace.asList().joinToString("\n")
+ val stackTrace = error.stackTraceToString()
val randomId = UUID.randomUUID().toString()
- errorMessages[randomId] = "```$errorMessage\nCaused at:\n$stackTrace```"
+
+ errorMessages[randomId] =
+ "```\nSkyHanni ${SkyHanniMod.version}: $message\n$stackTrace```"
LorenzUtils.clickableChat(
- "§cSkyHanni ${SkyHanniMod.version} $message. Click here to copy the error into the clipboard.",
+ "§c[SkyHanni ${SkyHanniMod.version}]: $message. Click here to copy the error into the clipboard.",
"shcopyerror $randomId"
)
}