Skip to content

Commit

Permalink
Force update placeholders on every vote to prevent issues
Browse files Browse the repository at this point in the history
  • Loading branch information
BenCodez committed Oct 22, 2023
1 parent 1a78a23 commit f131ce9
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,7 @@ public void onplayerVote(PlayerVoteEvent event) {
user.addPoints();
}
user.checkDayVoteStreak(event.isForceBungee());

if (plugin.getConfigFile().isLimitMonthlyVotes()) {
int value = 0;
if (event.isBungee()) {
Expand Down Expand Up @@ -249,6 +249,10 @@ public void run() {
event.isForceBungee(), voteTime);
plugin.getServer().getPluginManager().callEvent(postVoteEvent);

if (user.isOnline()) {
plugin.getPlaceholders().onUpdate(user, true);
}

if (!user.isOnline()) {
user.clearCache();
}
Expand Down

0 comments on commit f131ce9

Please sign in to comment.