Skip to content

Commit

Permalink
Moved custom files
Browse files Browse the repository at this point in the history
  • Loading branch information
DustinRepo committed Mar 17, 2022
1 parent fbc61ee commit b29538e
Show file tree
Hide file tree
Showing 4 changed files with 2 additions and 2 deletions.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/me/dustin/chatbot/command/CommandManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public void init() {
e.printStackTrace();
}
});
File customCommandsFile = new File(new File("").getAbsolutePath(), "custom.json");
File customCommandsFile = new File(new File("").getAbsolutePath() + File.separator + "custom", "custom.json");
if (customCommandsFile.exists()) {
JsonArray array = GeneralHelper.gson.fromJson(GeneralHelper.readFile(customCommandsFile), JsonArray.class);
for (int i = 0; i < array.size(); i++) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public class AnnouncementProcess extends ChatBotProcess {
private final ArrayList<String> announcements = new ArrayList<>();
public AnnouncementProcess(ClientConnection clientConnection) {
super(clientConnection);
File customCommandsFile = new File(new File("").getAbsolutePath(), "announcements.json");
File customCommandsFile = new File(new File("").getAbsolutePath() + File.separator + "custom", "announcements.json");
if (customCommandsFile.exists()) {
JsonArray array = GeneralHelper.gson.fromJson(GeneralHelper.readFile(customCommandsFile), JsonArray.class);
for (int i = 0; i < array.size(); i++) {
Expand Down

0 comments on commit b29538e

Please sign in to comment.