[BREAK] Use Strings for Channel ID's instead of Long

This commit is contained in:
2023-11-21 18:09:16 +02:00
parent 314001b206
commit 57bac96b6c
2 changed files with 5 additions and 5 deletions

View File

@@ -32,15 +32,15 @@ public class ChannelWebhookConfig {
public static class Channels {
@Path("chatChannelID")
@SpecComment("REQUIRED! The ID of the channel to post in and relay messages from. This is still needed, even in webhook mode")
public long chatChannelID = 0;
public String chatChannelID = "0";
@Path("eventsChannelID")
@SpecComment("If this ID is set, event messages will be posted in this channel instead of the chat channel")
public long eventsChannelID = 0;
public String eventsChannelID = "0";
@Path("consoleChannelID")
@SpecComment("If this ID is set, console messages sent after the bot started will be relayed here")
public long consoleChannelID = 0;
public String consoleChannelID = "0";
}
public static class Webhooks {

View File

@@ -142,8 +142,8 @@ public class PermissionChecker {
});
}
private static void checkChannelPerms(Long channelID, String channelName, AtomicInteger errCount, StringBuilder builder, Member bot, boolean channelRequired, boolean isChat) {
if (channelRequired && channelID == 0) {
private static void checkChannelPerms(String channelID, String channelName, AtomicInteger errCount, StringBuilder builder, Member bot, boolean channelRequired, boolean isChat) {
if (channelRequired && channelID.equalsIgnoreCase("0")) {
errCount.incrementAndGet();
builder.append(errCount.get())
.append(") ")