mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-12-01 17:36:46 +01:00
Increase attempt counter after the apply
This commit is contained in:
parent
216ecc465d
commit
c24c19f5f5
@ -51,8 +51,6 @@ public class PlayerProfileLoadingTask extends BukkitRunnable {
|
|||||||
player.sendMessage(LocaleLoader.getString("Profile.Loading.Start"));
|
player.sendMessage(LocaleLoader.getString("Profile.Loading.Start"));
|
||||||
}
|
}
|
||||||
|
|
||||||
// Increment attempt counter and try
|
|
||||||
attempt++;
|
|
||||||
PlayerProfile profile = mcMMO.getDatabaseManager().loadPlayerProfile(player.getName(), player.getUniqueId(), true);
|
PlayerProfile profile = mcMMO.getDatabaseManager().loadPlayerProfile(player.getName(), player.getUniqueId(), true);
|
||||||
// If successful, schedule the apply
|
// If successful, schedule the apply
|
||||||
if (profile.isLoaded()) {
|
if (profile.isLoaded()) {
|
||||||
@ -63,6 +61,9 @@ public class PlayerProfileLoadingTask extends BukkitRunnable {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Increment attempt counter and try
|
||||||
|
attempt++;
|
||||||
|
|
||||||
// If we've failed five times, give up
|
// If we've failed five times, give up
|
||||||
if (attempt >= MAX_TRIES) {
|
if (attempt >= MAX_TRIES) {
|
||||||
mcMMO.p.getLogger().severe("Giving up on attempting to load the PlayerProfile for " + player.getName());
|
mcMMO.p.getLogger().severe("Giving up on attempting to load the PlayerProfile for " + player.getName());
|
||||||
|
Loading…
Reference in New Issue
Block a user