diff --git a/VotingPlugin/src/com/bencodez/votingplugin/cooldown/CoolDownCheck.java b/VotingPlugin/src/com/bencodez/votingplugin/cooldown/CoolDownCheck.java index 034d752d9..ac333db4d 100644 --- a/VotingPlugin/src/com/bencodez/votingplugin/cooldown/CoolDownCheck.java +++ b/VotingPlugin/src/com/bencodez/votingplugin/cooldown/CoolDownCheck.java @@ -92,12 +92,11 @@ public synchronized void checkPerSite(VotingPluginUser user) { HashMap coolDownChecks = user.getCoolDownCheckSiteList(); boolean changed = false; for (VoteSite site : plugin.getVoteSites()) { - if (user.canVoteSite(site)) { - if (!coolDownChecks.containsKey(site.getKey()) - || !coolDownChecks.get(site.getKey()).booleanValue()) { + if (!coolDownChecks.containsKey(site.getKey()) || !coolDownChecks.get(site.getKey()).booleanValue()) { + if (user.canVoteSite(site)) { coolDownChecks.put(site.getKey(), Boolean.TRUE); changed = true; - plugin.extraDebug("Trigger votesitecooldownend event for " + user.getUUID()); + plugin.extraDebug("Triggering votesitecooldownend event for " + user.getUUID()); PlayerVoteSiteCoolDownEndEvent event = new PlayerVoteSiteCoolDownEndEvent(user, site); plugin.getServer().getPluginManager().callEvent(event); } @@ -152,7 +151,7 @@ public void run() { check(uuid); } } - }, time + 60, TimeUnit.SECONDS); + }, time, TimeUnit.SECONDS); allSiteTasks.put(uuid, scheduledFuture); } @@ -220,7 +219,7 @@ public void scheduleGlobalCheckVoteSite(VoteSite site) { public void run() { checkAllVoteSite(site); } - }, time + 65, TimeUnit.SECONDS); + }, time + 90, TimeUnit.SECONDS); plugin.getLogger().info( "Checking vote delay daily cooldown events/rewards in " + time + " seconds for " + site.getKey());