Code cleanup

This commit is contained in:
2022-01-30 15:03:47 -06:00
parent d4761d4386
commit 4a05d90c17
25 changed files with 191 additions and 97 deletions

View File

@ -8,7 +8,7 @@ import org.bukkit.Bukkit;
public class DataUtils
{
/* PLEX PLAYER METHODS */
/* PLEX PLAYER METHODS */
public static boolean hasPlayedBefore(UUID uuid)
{
@ -61,7 +61,9 @@ public class DataUtils
if (Plex.get().getStorageType() == StorageType.MONGODB)
{
Plex.get().getMongoPlayerData().save(plexPlayer);
} else {
}
else
{
Plex.get().getSqlPlayerData().insert(plexPlayer);
}
}

View File

@ -54,7 +54,9 @@ public class SQLPlayerData
String rankName = set.getString("rank").toUpperCase();
long coins = set.getLong("coins");
boolean vanished = set.getBoolean("vanished");
List<String> ips = new Gson().fromJson(set.getString("ips"), new TypeToken<List<String>>(){}.getType());
List<String> ips = new Gson().fromJson(set.getString("ips"), new TypeToken<List<String>>()
{
}.getType());
plexPlayer.setName(name);
plexPlayer.setLoginMSG(loginMSG);
plexPlayer.setPrefix(prefix);