Skip to content

Commit 9514e81

Browse files
committed
Fix up some commands
1 parent 8083230 commit 9514e81

4 files changed

Lines changed: 18 additions & 19 deletions

File tree

bot/src/main/java/me/duncte123/skybot/commands/uncategorized/HelpCommand.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,14 +88,16 @@ private boolean isCategory(String name) {
8888
}
8989

9090
private void sendHelp(CommandContext ctx, EmbedBuilder embed) {
91-
ctx.getAuthor()
91+
sendEmbed(ctx, embed);
92+
93+
/*ctx.getAuthor()
9294
.openPrivateChannel()
9395
.flatMap((pc) -> pc.sendMessageEmbeds(embed.build()))
9496
.queue(
9597
(msg) -> sendMsg(ctx, ctx.getAuthor().getAsMention() + " help has been sent to your private messages"),
9698
//When sending fails, send to the channel
9799
(err) -> sendMsg(ctx, "You can check out my commands here:\nhttps://duncte.bot/commands")
98-
);
100+
);*/
99101
}
100102

101103
private void sendCommandHelp(CommandContext ctx, String toSearch, CommandManager manager, String prefix) {

bot/src/main/java/me/duncte123/skybot/database/RedisConnection.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,8 @@
3232

3333
public class RedisConnection implements RedisDB {
3434
/* seconds * minutes * hours * days */
35-
private static final long TWO_WEEKS_IN_SECONDS = 60L * 60L * 24L * 14L;
3635
private static final long ONE_MONTH_IN_SECONDS = 60L * 60L * 24L * 31L;
3736

38-
@SuppressWarnings("NotNullFieldNotInitialized")
3937
@NotNull
4038
private JedisPool pool;
4139
private boolean canConnect = true;
@@ -83,7 +81,6 @@ public void storeMessage(@NotNull MessageData data) {
8381
data.getMessageIdString(),
8482
data.toMap()
8583
);
86-
// normal 2 weeks, patreon 1 month
8784
jedis.expire(data.getMessageIdString(), ONE_MONTH_IN_SECONDS);
8885
}
8986
}

bot/src/main/java/me/duncte123/skybot/utils/HelpEmbeds.java

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -39,14 +39,14 @@ public class HelpEmbeds {
3939
private static String MAIN_COMMANDS = "";
4040
private static String MUSIC_COMMANDS = "";
4141
private static String ANIMALS_COMMANDS = "";
42-
private static String WEEB_COMMANDS = "";
43-
private static String LGBTQ_COMMANDS = "";
42+
// private static String WEEB_COMMANDS = "";
43+
// private static String LGBTQ_COMMANDS = "";
4444
private static String FUN_COMMANDS = "";
4545
private static String UTILS_COMMANDS = "";
4646
private static String MODERATION_COMMANDS = "";
4747
private static String ADMINISTRATION_COMMANDS = "";
48-
private static String PATRON_COMMANDS = "";
49-
private static String NSFW_COMMANDS = "";
48+
// private static String PATRON_COMMANDS = "";
49+
// private static String NSFW_COMMANDS = "";
5050
/// </editor-fold>
5151

5252
private static final boolean INLINE = false;
@@ -97,10 +97,10 @@ public static void init(final CommandManager manager) {
9797
case MODERATION -> MODERATION_COMMANDS = joinedCommands;
9898
case ADMINISTRATION -> ADMINISTRATION_COMMANDS = joinedCommands;
9999
case UTILS -> UTILS_COMMANDS = joinedCommands;
100-
case PATRON -> PATRON_COMMANDS = joinedCommands;
101-
case WEEB -> WEEB_COMMANDS = joinedCommands;
102-
case NSFW -> NSFW_COMMANDS = joinedCommands;
103-
case LGBTQ -> LGBTQ_COMMANDS = joinedCommands;
100+
// case PATRON -> PATRON_COMMANDS = joinedCommands;
101+
// case WEEB -> WEEB_COMMANDS = joinedCommands;
102+
// case NSFW -> NSFW_COMMANDS = joinedCommands;
103+
// case LGBTQ -> LGBTQ_COMMANDS = joinedCommands;
104104
}
105105
}
106106
catch (Exception e) {
@@ -131,11 +131,11 @@ private static MessageEmbed.Field getFieldForCategory(CommandCategory category)
131131
case MODERATION -> MODERATION_COMMANDS;
132132
case ADMINISTRATION -> ADMINISTRATION_COMMANDS;
133133
case UTILS -> UTILS_COMMANDS;
134-
case PATRON -> PATRON_COMMANDS;
135-
case WEEB -> WEEB_COMMANDS;
136-
case NSFW -> NSFW_COMMANDS;
137-
case LGBTQ -> LGBTQ_COMMANDS;
138-
case UNLISTED -> null;
134+
// case PATRON -> PATRON_COMMANDS;
135+
// case WEEB -> WEEB_COMMANDS;
136+
// case NSFW -> NSFW_COMMANDS;
137+
// case LGBTQ -> LGBTQ_COMMANDS;
138+
default -> null;
139139
};
140140

141141
if (commands == null) {

settings.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ fun VersionCatalogBuilder.bot() {
7474
library("duration-parser", "me.duncte123", "durationParser").version("1.1.3")
7575
// library("emoji-java", "com.github.minndevelopment", "emoji-java").version("master-SNAPSHOT")
7676
library("jemoji", "net.fellbaum", "jemoji").version("1.5.2")
77-
library("botCommons", "me.duncte123", "botCommons").version("3.1.18")
77+
library("botCommons", "me.duncte123", "botCommons").version("3.2.19")
7878

7979
bundle("featureLibs", listOf("botCommons", "weebjava", "loadingBar", "jagTag", "wolfram-alpha", "duration-parser", "jemoji"))
8080

0 commit comments

Comments
 (0)