Compare commits
2 Commits
514f4757a9
...
6fef1d0092
Author | SHA1 | Date | |
---|---|---|---|
6fef1d0092 | |||
f7aba7a49b |
@ -19,7 +19,7 @@ public class ChannelUtils {
|
||||
* @return the user with the given id
|
||||
*/
|
||||
private static TextChannel getTextChannel(String id, int retries) {
|
||||
if (retries >= 25) {
|
||||
if (retries >= 10) {
|
||||
log.error("Failed to find user \"{}\" after {} retries.", id, retries);
|
||||
return null;
|
||||
}
|
||||
|
@ -19,7 +19,7 @@ public class UserUtils {
|
||||
* @return the user with the given id
|
||||
*/
|
||||
private static User getUser(String id, int retries) {
|
||||
if (retries >= 25) {
|
||||
if (retries >= 10) {
|
||||
log.error("Failed to find user \"{}\" after {} retries.", id, retries);
|
||||
return null;
|
||||
}
|
||||
|
@ -36,7 +36,7 @@ public class BirthdayFeature extends Feature implements EventListener {
|
||||
private void checkBirthdays() {
|
||||
for (Guild guild : DiscordService.JDA.getGuilds()) {
|
||||
BatGuild batGuild = guildService.getGuild(guild.getId());
|
||||
if (batGuild == null) {
|
||||
if (batGuild.getFeatureProfile().isFeatureDisabled(this)) { // Check if the feature is disabled
|
||||
continue;
|
||||
}
|
||||
BirthdayProfile profile = batGuild.getBirthdayProfile();
|
||||
|
@ -38,6 +38,10 @@ public class MinecraftFeature extends Feature {
|
||||
public void checkServers() {
|
||||
for (Guild guild : DiscordService.JDA.getGuilds()) {
|
||||
BatGuild batGuild = guildService.getGuild(guild.getId());
|
||||
if (batGuild.getFeatureProfile().isFeatureDisabled(this)) { // Check if the feature is disabled
|
||||
continue;
|
||||
}
|
||||
|
||||
batGuild.getMinecraftProfile().checkServers();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user