Fix compilation errors due to API change

This commit is contained in:
2022-05-19 00:20:58 -05:00
parent 10b073a14b
commit e3a3756c26
2 changed files with 9 additions and 8 deletions
+8 -6
View File
@@ -16,7 +16,6 @@ import lombok.Getter;
import java.util.Arrays;
//TODO: Implement mongodb
@Getter
public class Guilds extends PlexModule
@@ -43,13 +42,16 @@ public class Guilds extends PlexModule
{
getPlex().getMongoConnection().getDatastore().getMapper().map(Guild.class);
getPlex().getMongoConnection().getDatastore().ensureIndexes();
} else {
}
else
{
SQLManager.makeTables();
sqlGuildManager = new SQLGuildManager();
sqlGuildManager.getGuilds().whenComplete((guilds, throwable) -> {
PlexLog.debug("Finished loading {0} guilds", guilds.size());
guilds.forEach(guildHolder::addGuild);
this.registerCommand(new GuildCommand());
sqlGuildManager.getGuilds().whenComplete((guilds, throwable) ->
{
PlexLog.debug("Finished loading {0} guilds", guilds.size());
guilds.forEach(guildHolder::addGuild);
this.registerCommand(new GuildCommand());
});
}