This commit is contained in:
@@ -3,6 +3,7 @@ package tech.allydoes.database;
|
||||
import org.apache.logging.log4j.LogManager;
|
||||
import org.apache.logging.log4j.Logger;
|
||||
import tech.allydoes.Constants;
|
||||
import tech.allydoes.door.DoorStatus;
|
||||
|
||||
import java.sql.*;
|
||||
import java.util.ArrayList;
|
||||
@@ -90,6 +91,7 @@ public class DatabaseManager {
|
||||
preparedStatement.setString(3, messageId);
|
||||
if (preparedStatement.execute()) {
|
||||
LOGGER.debug("Notifier for guild {}, channel {}, message {} added successfully.", guildId, channelId, messageId);
|
||||
DoorStatus.setDoorStatus(DoorStatus.getCurrentStatus());
|
||||
}
|
||||
}
|
||||
} catch (SQLException e) {
|
||||
|
||||
@@ -26,7 +26,6 @@ public class SaveChannelCommand implements Command {
|
||||
String channelId = event.getChannel().getId();
|
||||
String messageId = embedMessage.getId();
|
||||
Main.getDatabaseManager().putNotifier(guildId, channelId, messageId);
|
||||
DoorStatus.setDoorStatus(DoorStatus.getCurrentStatus());
|
||||
});
|
||||
event.getHook().editOriginal("Channel saved!").queue();
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user