Clean up irrelevant/fixed TODOs

This commit is contained in:
Salmonllama 2020-11-27 12:10:41 -05:00
parent 969af64400
commit 3c4c4c38bd
7 changed files with 9 additions and 11 deletions

View File

@ -17,8 +17,7 @@ import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication; import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.autoconfigure.SpringBootApplication;
// TODO: auto-switching status messages.
// TODO: Add an official Logger --> logging to Discord, not console
@SpringBootApplication @SpringBootApplication
public class Main { public class Main {
@ -28,7 +27,6 @@ public class Main {
public static void main(String[] args) { public static void main(String[] args) {
String configLocation = Constants.BOT_FOLDER.concat(Constants.CONFIG_NAME); String configLocation = Constants.BOT_FOLDER.concat(Constants.CONFIG_NAME);
BotConfig.initConfig(configLocation, false); BotConfig.initConfig(configLocation, false);
// TODO: Use args to dictate newFiling. Also use args to dictate database setup.
FSDB.init(); FSDB.init();

View File

@ -16,7 +16,7 @@ import java.awt.*;
import java.util.Arrays; import java.util.Arrays;
import java.util.List; import java.util.List;
public class CreateGalleryCommand extends Command { // TODO: This command needs help. public class CreateGalleryCommand extends Command {
@Override public String name() { return "Create Gallery"; } @Override public String name() { return "Create Gallery"; }
@Override public String description() { return "Creates a channel gallery, tracking any posted images"; } @Override public String description() { return "Creates a channel gallery, tracking any posted images"; }
@Override public String usage() { return "creategallery <String tag>"; } @Override public String usage() { return "creategallery <String tag>"; }
@ -27,7 +27,7 @@ public class CreateGalleryCommand extends Command { // TODO: This command needs
@Override @Override
public void onCommand(CommandContext ctx) { public void onCommand(CommandContext ctx) {
if (ctx.isPrivateMessage()) { if (ctx.isPrivateMessage()) {
ctx.reply("This command can only be used in a server!"); // TODO: Stop this. Turn this into a preset no-no embed. ctx.reply("This command can only be used in a server!");
return; return;
} }
if (ctx.getArgs().length < 1) { if (ctx.getArgs().length < 1) {

View File

@ -49,7 +49,7 @@ public class OutfitCommand extends Command {
switch (args.length) { switch (args.length) {
case 0: case 0:
// Send one single random outfit of the given tag // Send one single random outfit of the given tag
OutfitController.findRandomByTag(command).thenAccept(possibleOutfit -> { // TODO: Add an orElse case OutfitController.findRandomByTag(command).thenAccept(possibleOutfit -> {
possibleOutfit.ifPresent(outfit -> { possibleOutfit.ifPresent(outfit -> {
ctx.getApi().getUserById(outfit.getSubmitter()).thenAcceptAsync(user -> { ctx.getApi().getUserById(outfit.getSubmitter()).thenAcceptAsync(user -> {
EmbedBuilder response = new EmbedBuilder() EmbedBuilder response = new EmbedBuilder()
@ -91,7 +91,7 @@ public class OutfitCommand extends Command {
}); });
}); });
} else { } else {
ctx.reply("Improper command usage"); // TODO: Logging update reminder ctx.reply("Improper command usage");
} }
} }
} }

View File

@ -27,7 +27,7 @@ public class StatsCommand extends Command {
int userCount = ctx.getApi().getCachedUsers().size(); // Will these be accurate with sharding? int userCount = ctx.getApi().getCachedUsers().size(); // Will these be accurate with sharding?
int serverCount = ctx.getApi().getServers().size(); int serverCount = ctx.getApi().getServers().size();
EmbedBuilder embed = new EmbedBuilder(); // TODO: Standard embeds yeah? EmbedBuilder embed = new EmbedBuilder();
embed.setTitle("Stats"); embed.setTitle("Stats");
embed.addField("Users:", String.valueOf(userCount)); embed.addField("Users:", String.valueOf(userCount));
embed.addField("Servers:", String.valueOf(serverCount)); embed.addField("Servers:", String.valueOf(serverCount));

View File

@ -51,7 +51,7 @@ public class ImgurAPIConnection {
try (Response response = client.newCall(request).execute()) { try (Response response = client.newCall(request).execute()) {
json = new JSONObject(response.body().string()).getJSONObject("data"); json = new JSONObject(response.body().string()).getJSONObject("data");
} catch (IOException e) { } catch (IOException e) {
e.printStackTrace(); // TODO: Do tha logging thang. e.printStackTrace();
return null; return null;
} }

View File

@ -19,7 +19,7 @@ class Registry {
commandsMap = new HashMap<>(); commandsMap = new HashMap<>();
} }
Predicate<String> valueMatch(String input) { // TODO: Move to a helper class Predicate<String> valueMatch(String input) {
return str -> str.equals(input); return str -> str.equals(input);
} }

View File

@ -10,7 +10,7 @@ import org.javacord.api.listener.server.ServerJoinListener;
public class ServerJoined implements ServerJoinListener { public class ServerJoined implements ServerJoinListener {
public void onServerJoin(ServerJoinEvent event) { // TODO: This needs fixing yo public void onServerJoin(ServerJoinEvent event) {
// db.newServerProcess(event.getServer()); // db.newServerProcess(event.getServer());
// EmbedBuilder embed = new EmbedBuilder() // EmbedBuilder embed = new EmbedBuilder()