diff --git a/Essentials/src/main/java/com/earth2me/essentials/utils/CommandMapUtil.java b/Essentials/src/main/java/com/earth2me/essentials/utils/CommandMapUtil.java index d861ce715f4..287da28c4c6 100644 --- a/Essentials/src/main/java/com/earth2me/essentials/utils/CommandMapUtil.java +++ b/Essentials/src/main/java/com/earth2me/essentials/utils/CommandMapUtil.java @@ -4,6 +4,7 @@ import com.google.gson.GsonBuilder; import com.google.gson.JsonArray; import com.google.gson.JsonObject; +import com.google.gson.JsonPrimitive; import net.ess3.api.IEssentials; import org.bukkit.command.Command; import org.bukkit.command.FormattedCommandAlias; @@ -59,8 +60,8 @@ public static JsonObject toJson(IEssentials ess, Command value) { } else if (value instanceof FormattedCommandAlias) { json.addProperty("source", "commands.yml"); final JsonArray formatStrings = new JsonArray(); - for (String entry : ess.getFormattedCommandAliasProvider().getFormatStrings((FormattedCommandAlias) value)) { - formatStrings.add(entry); + for (final String entry : ess.getFormattedCommandAliasProvider().getFormatStrings((FormattedCommandAlias) value)) { + formatStrings.add(new JsonPrimitive(entry)); } json.add("bukkit_aliases", formatStrings); }