mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 13:16:45 +01:00
Properly convert SQL to Flatfile when UUIDs are null
This commit is contained in:
parent
30ebe318e0
commit
ca6dc5195d
@ -272,7 +272,7 @@ public final class FlatfileDatabaseManager implements DatabaseManager {
|
||||
while ((line = in.readLine()) != null) {
|
||||
// Read the line in and copy it to the output if it's not the player we want to edit
|
||||
String[] character = line.split(":");
|
||||
if (!character[41].equalsIgnoreCase(uuid.toString()) && !character[0].equalsIgnoreCase(playerName)) {
|
||||
if (!(uuid != null && character[41].equalsIgnoreCase(uuid.toString())) && !character[0].equalsIgnoreCase(playerName)) {
|
||||
writer.append(line).append("\r\n");
|
||||
}
|
||||
else {
|
||||
@ -319,7 +319,7 @@ public final class FlatfileDatabaseManager implements DatabaseManager {
|
||||
writer.append(mobHealthbarType == null ? Config.getInstance().getMobHealthbarDefault().toString() : mobHealthbarType.toString()).append(":");
|
||||
writer.append(profile.getSkillLevel(SkillType.ALCHEMY)).append(":");
|
||||
writer.append(profile.getSkillXpLevel(SkillType.ALCHEMY)).append(":");
|
||||
writer.append(uuid.toString()).append(":");
|
||||
writer.append(uuid != null ? uuid.toString() : "NULL").append(":");
|
||||
writer.append(profile.getScoreboardTipsShown()).append(":");
|
||||
writer.append("\r\n");
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user