We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e653eed commit c5493c3Copy full SHA for c5493c3
src/main/kotlin/xyz/xasmc/hashbook/util/MessageUtil.kt
@@ -24,7 +24,7 @@ object MessageUtil {
24
}
25
26
fun shortHashMessage(hash: String): String {
27
- val shortHash = hash.substring(0..6)
+ val shortHash = hash.substring(0..6.coerceAtMost(hash.length))
28
return copyMsg("$shortHash <i><gold>[点击复制]</gold></i>", hash, "<green>$hash</green>")
29
30
0 commit comments