aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/io
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/io')
-rw-r--r--src/main/java/io/github/moulberry/notenoughupdates/util/DiscordMarkdownBuilder.java7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/main/java/io/github/moulberry/notenoughupdates/util/DiscordMarkdownBuilder.java b/src/main/java/io/github/moulberry/notenoughupdates/util/DiscordMarkdownBuilder.java
index 3c6c5f3d..941615fb 100644
--- a/src/main/java/io/github/moulberry/notenoughupdates/util/DiscordMarkdownBuilder.java
+++ b/src/main/java/io/github/moulberry/notenoughupdates/util/DiscordMarkdownBuilder.java
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2022 NotEnoughUpdates contributors
+ * Copyright (C) 2022-2023 NotEnoughUpdates contributors
*
* This file is part of NotEnoughUpdates.
*
@@ -33,7 +33,10 @@ public class DiscordMarkdownBuilder {
}
public DiscordMarkdownBuilder append(String key, Object value) {
- builder.append("[").append(key).append("]").append("[").append(value).append("]").append("\n");
+ if (!key.isEmpty()) {
+ builder.append("[").append(key).append("]");
+ }
+ builder.append("[").append(value).append("]").append("\n");
return this;
}