Some revert, remove useless code from upstream

This commit is contained in:
Dreeam 2023-12-05 09:23:35 -05:00
parent 89b0d59ab9
commit f1f6edd848
3 changed files with 1 additions and 22 deletions

View File

@ -1129,7 +1129,7 @@
<dependency>
<groupId>com.h2database</groupId>
<artifactId>h2</artifactId>
<version>2.2.220</version>
<version>2.1.214</version>
<scope>test</scope>
</dependency>

View File

@ -76,12 +76,6 @@ public class GeoIpService {
* @return True if the data is available, false otherwise.
*/
private synchronized boolean isDataAvailable() {
// If this feature is disabled, just stop
if (!settings.getProperty(ProtectionSettings.ENABLE_GEOIP)) {
return false;
}
if (downloading) {
// we are currently downloading the database
return false;

View File

@ -20,21 +20,6 @@ public final class ProtectionSettings implements SettingsHolder {
public static final Property<Boolean> ENABLE_PROTECTION_REGISTERED =
newProperty("Protection.enableProtectionRegistered", true);
@Comment("Enable GeoIp database")
public static final Property<Boolean> ENABLE_GEOIP =
newProperty("Protection.geoIpDatabase.enabled", true);
@Comment({"The MaxMind clientId used to download the GeoIp database,",
"get one at https://www.maxmind.com/en/accounts/current/license-key",
"The EssentialsX project has a very useful tutorial on how to generate",
"the license key: https://github.com/EssentialsX/Wiki/blob/master/GeoIP.md"})
public static final Property<String> MAXMIND_API_CLIENT_ID =
newProperty("Protection.geoIpDatabase.clientId", "");
@Comment("The MaxMind licenseKey used to download the GeoIp database.")
public static final Property<String> MAXMIND_API_LICENSE_KEY =
newProperty("Protection.geoIpDatabase.licenseKey", "");
@Comment({
"Countries allowed to join the server and register. For country codes, see",
"https://dev.maxmind.com/geoip/legacy/codes/iso3166/",