seePreReleaseUpdates #1

This commit is contained in:
2022-11-14 22:59:17 +01:00
parent f0b5b2e65b
commit 8114035cd9
6 changed files with 38 additions and 18 deletions

View File

@@ -31,6 +31,7 @@ public class T2CBupdateAPI {
String pluginVersion = plugin.getDescription().getVersion();
String value;
if (webData.isPreRelease()) {
if (!T2CBlibConfig.getSeePreReleaseUpdates()) return;
value = UpdateType.PRERELEASE.text;
if (publicVersion.toLowerCase().contains("dev")) {
value = UpdateType.DEVELOPMENT.text;

View File

@@ -36,6 +36,7 @@ public class T2CBlibConfig {
Configuration configuration = ConfigurationProvider.getProvider(YamlConfiguration.class).load(config);
updateTimer = configuration.getInt("UpdateCheck.TimerInMin");
seePreReleaseUpdates = configuration.getBoolean("UpdateCheck.SeePreReleaseUpdates");
apiCommandGUIEnable = configuration.getBoolean("API.CommandGUI.Enable");
apiAutoResponse = configuration.getBoolean("API.AutoResponse.Enable");
@@ -43,6 +44,7 @@ public class T2CBlibConfig {
}
private static Integer updateTimer;
private static Boolean seePreReleaseUpdates;
private static Boolean apiCommandGUIEnable;
private static Boolean apiAutoResponse;
private static Boolean apiOpSecurity;
@@ -51,6 +53,10 @@ public class T2CBlibConfig {
return updateTimer;
}
public static Boolean getSeePreReleaseUpdates() {
return seePreReleaseUpdates;
}
public static Boolean getApiCommandGUIEnable() {
return apiCommandGUIEnable;
}