mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2025-03-07 17:28:03 +08:00
Fix bugs
This commit is contained in:
parent
4a78790638
commit
c72440d689
Binary file not shown.
@ -32,7 +32,11 @@ public class FakeOfflinePlayer implements OfflinePlayer {
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
return data.getName();
|
||||
String name = data.getName();
|
||||
if (name == null) {
|
||||
name = "null";
|
||||
}
|
||||
return name;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -93,17 +93,7 @@ public class ProtocolTable extends Table {
|
||||
}
|
||||
|
||||
private boolean exists(UUID uuid) throws SQLException {
|
||||
PreparedStatement statement = null;
|
||||
ResultSet set = null;
|
||||
try {
|
||||
statement = prepareStatement("SELECT " + columnUUID + " FROM " + tableName + " WHERE " + columnUUID + "=?");
|
||||
statement.setString(1, uuid.toString());
|
||||
set = statement.executeQuery();
|
||||
return set.next();
|
||||
} finally {
|
||||
close(set);
|
||||
close(statement);
|
||||
}
|
||||
return getProtocolVersion(uuid) != -1;
|
||||
}
|
||||
|
||||
private void updateProtocolVersion(UUID uuid, int version) throws SQLException {
|
||||
|
Loading…
Reference in New Issue
Block a user