|
|
@ -128,15 +128,14 @@ public class dbContractHandler extends dbHandlerBase { |
|
|
|
} |
|
|
|
} |
|
|
|
}else{ |
|
|
|
}else{ |
|
|
|
try (Connection connection = DbManager.getConnection(); |
|
|
|
try (Connection connection = DbManager.getConnection(); |
|
|
|
PreparedStatement preparedStatement = connection.prepareStatement("SELECT * FROM `static_npc_contract_selltype` WHERE `type` = ?;")) { |
|
|
|
PreparedStatement preparedStatement = connection.prepareStatement("SELECT * FROM `static_npc_contract_selltype`;")) { |
|
|
|
|
|
|
|
|
|
|
|
preparedStatement.setInt(1, 2); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ResultSet rs = preparedStatement.executeQuery(); |
|
|
|
ResultSet rs = preparedStatement.executeQuery(); |
|
|
|
|
|
|
|
|
|
|
|
while (rs.next()) { |
|
|
|
while (rs.next()) { |
|
|
|
if(!contract.getBuySkillToken().contains(rs.getInt("value"))) |
|
|
|
int value = rs.getInt("value"); |
|
|
|
contract.getBuySkillToken().add(rs.getInt("value")); |
|
|
|
if(!contract.getBuySkillToken().contains(value)) |
|
|
|
|
|
|
|
contract.getBuySkillToken().add(value); |
|
|
|
} |
|
|
|
} |
|
|
|
} catch (SQLException e) { |
|
|
|
} catch (SQLException e) { |
|
|
|
Logger.error(e); |
|
|
|
Logger.error(e); |
|
|
|