diff --git a/ArchiSteamFarm/BotConfig.cs b/ArchiSteamFarm/BotConfig.cs index 2399aa96c..342f4525f 100644 --- a/ArchiSteamFarm/BotConfig.cs +++ b/ArchiSteamFarm/BotConfig.cs @@ -37,37 +37,37 @@ namespace ArchiSteamFarm { [SuppressMessage("ReSharper", "ConvertToConstant.Global")] internal sealed class BotConfig { [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool AcceptGifts = false; + internal readonly bool AcceptGifts; [JsonProperty(Required = Required.DisallowNull)] internal readonly bool CardDropsRestricted = true; [JsonProperty] - internal readonly string CustomGamePlayedWhileFarming = null; + internal readonly string CustomGamePlayedWhileFarming; [JsonProperty] - internal readonly string CustomGamePlayedWhileIdle = null; + internal readonly string CustomGamePlayedWhileIdle; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool DismissInventoryNotifications = false; + internal readonly bool DismissInventoryNotifications; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool Enabled = false; + internal readonly bool Enabled; [JsonProperty(Required = Required.DisallowNull)] internal readonly EFarmingOrder FarmingOrder = EFarmingOrder.Unordered; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool FarmOffline = false; + internal readonly bool FarmOffline; [JsonProperty(Required = Required.DisallowNull)] internal readonly HashSet GamesPlayedWhileIdle = new HashSet(); [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool HandleOfflineMessages = false; + internal readonly bool HandleOfflineMessages; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool IsBotAccount = false; + internal readonly bool IsBotAccount; [JsonProperty(ObjectCreationHandling = ObjectCreationHandling.Replace, Required = Required.DisallowNull)] internal readonly HashSet LootableTypes = new HashSet { @@ -80,25 +80,25 @@ namespace ArchiSteamFarm { internal readonly CryptoHelper.ECryptoMethod PasswordFormat = CryptoHelper.ECryptoMethod.PlainText; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool Paused = false; + internal readonly bool Paused; [JsonProperty(Required = Required.DisallowNull)] internal readonly ERedeemingPreferences RedeemingPreferences = ERedeemingPreferences.None; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool SendOnFarmingFinished = false; + internal readonly bool SendOnFarmingFinished; [JsonProperty(Required = Required.DisallowNull)] - internal readonly byte SendTradePeriod = 0; + internal readonly byte SendTradePeriod; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool ShutdownOnFarmingFinished = false; + internal readonly bool ShutdownOnFarmingFinished; [JsonProperty(Required = Required.DisallowNull)] - internal readonly ulong SteamMasterClanID = 0; + internal readonly ulong SteamMasterClanID; [JsonProperty] - internal readonly string SteamTradeToken = null; + internal readonly string SteamTradeToken; [SuppressMessage("ReSharper", "CollectionNeverUpdated.Global")] [JsonProperty(Required = Required.DisallowNull)] diff --git a/ArchiSteamFarm/GlobalConfig.cs b/ArchiSteamFarm/GlobalConfig.cs index 3e026e86e..0214eda01 100644 --- a/ArchiSteamFarm/GlobalConfig.cs +++ b/ArchiSteamFarm/GlobalConfig.cs @@ -55,10 +55,10 @@ namespace ArchiSteamFarm { internal readonly byte ConnectionTimeout = DefaultConnectionTimeout; [JsonProperty] - internal readonly string CurrentCulture = null; + internal readonly string CurrentCulture; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool Debug = false; + internal readonly bool Debug; [JsonProperty(Required = Required.DisallowNull)] internal readonly byte FarmingDelay = 15; @@ -67,7 +67,7 @@ namespace ArchiSteamFarm { internal readonly byte GiftsLimiterDelay = 1; [JsonProperty(Required = Required.DisallowNull)] - internal readonly bool Headless = false; + internal readonly bool Headless; [JsonProperty(Required = Required.DisallowNull)] internal readonly byte IdleFarmingPeriod = 3; @@ -91,7 +91,7 @@ namespace ArchiSteamFarm { internal readonly bool Statistics = true; [JsonProperty(Required = Required.DisallowNull)] - internal readonly ulong SteamOwnerID = 0; + internal readonly ulong SteamOwnerID; [JsonProperty(Required = Required.DisallowNull)] internal readonly ProtocolType SteamProtocol = ProtocolType.Tcp; diff --git a/ConfigGenerator/BotConfig.cs b/ConfigGenerator/BotConfig.cs index 27b3e0a69..62b9886ab 100644 --- a/ConfigGenerator/BotConfig.cs +++ b/ConfigGenerator/BotConfig.cs @@ -39,41 +39,41 @@ namespace ConfigGenerator { [SuppressMessage("ReSharper", "UnusedMember.Global")] internal sealed class BotConfig : ASFConfig { [JsonProperty(Required = Required.DisallowNull)] - public bool AcceptGifts { get; set; } = false; + public bool AcceptGifts { get; set; } [LocalizedCategory("Performance")] [JsonProperty(Required = Required.DisallowNull)] public bool CardDropsRestricted { get; set; } = true; [JsonProperty] - public string CustomGamePlayedWhileFarming { get; set; } = null; + public string CustomGamePlayedWhileFarming { get; set; } [JsonProperty] - public string CustomGamePlayedWhileIdle { get; set; } = null; + public string CustomGamePlayedWhileIdle { get; set; } [JsonProperty(Required = Required.DisallowNull)] - public bool DismissInventoryNotifications { get; set; } = false; + public bool DismissInventoryNotifications { get; set; } [LocalizedCategory("Core")] [JsonProperty(Required = Required.DisallowNull)] - public bool Enabled { get; set; } = false; + public bool Enabled { get; set; } [JsonProperty(Required = Required.DisallowNull)] public EFarmingOrder FarmingOrder { get; set; } = EFarmingOrder.Unordered; [JsonProperty(Required = Required.DisallowNull)] - public bool FarmOffline { get; set; } = false; + public bool FarmOffline { get; set; } [JsonProperty(Required = Required.DisallowNull)] public List GamesPlayedWhileIdle { get; set; } = new List(); [LocalizedCategory("Advanced")] [JsonProperty(Required = Required.DisallowNull)] - public bool HandleOfflineMessages { get; set; } = false; + public bool HandleOfflineMessages { get; set; } [LocalizedCategory("Advanced")] [JsonProperty(Required = Required.DisallowNull)] - public bool IsBotAccount { get; set; } = false; + public bool IsBotAccount { get; set; } [LocalizedCategory("Advanced")] [JsonProperty(ObjectCreationHandling = ObjectCreationHandling.Replace, Required = Required.DisallowNull)] @@ -89,7 +89,7 @@ namespace ConfigGenerator { [LocalizedCategory("Advanced")] [JsonProperty(Required = Required.DisallowNull)] - public bool Paused { get; set; } = false; + public bool Paused { get; set; } [LocalizedCategory("Advanced")] [Editor(typeof(FlagEnumUiEditor), typeof(UITypeEditor))] @@ -97,21 +97,21 @@ namespace ConfigGenerator { public ERedeemingPreferences RedeemingPreferences { get; set; } = ERedeemingPreferences.None; [JsonProperty(Required = Required.DisallowNull)] - public bool SendOnFarmingFinished { get; set; } = false; + public bool SendOnFarmingFinished { get; set; } [JsonProperty(Required = Required.DisallowNull)] - public byte SendTradePeriod { get; set; } = 0; + public byte SendTradePeriod { get; set; } [JsonProperty(Required = Required.DisallowNull)] - public bool ShutdownOnFarmingFinished { get; set; } = false; + public bool ShutdownOnFarmingFinished { get; set; } [LocalizedCategory("Core")] [JsonProperty] - public string SteamLogin { get; set; } = null; + public string SteamLogin { get; set; } [LocalizedCategory("Access")] [JsonProperty(Required = Required.DisallowNull)] - public ulong SteamMasterClanID { get; set; } = 0; + public ulong SteamMasterClanID { get; set; } [LocalizedCategory("Access")] [JsonProperty] @@ -120,11 +120,11 @@ namespace ConfigGenerator { [LocalizedCategory("Core")] [JsonProperty] [PasswordPropertyText(true)] - public string SteamPassword { get; set; } = null; + public string SteamPassword { get; set; } [LocalizedCategory("Access")] [JsonProperty] - public string SteamTradeToken { get; set; } = null; + public string SteamTradeToken { get; set; } [LocalizedCategory("Access")] [Editor(typeof(GenericDictionaryEditor), typeof(UITypeEditor))] diff --git a/ConfigGenerator/GlobalConfig.cs b/ConfigGenerator/GlobalConfig.cs index b0077c631..b9a620e26 100644 --- a/ConfigGenerator/GlobalConfig.cs +++ b/ConfigGenerator/GlobalConfig.cs @@ -58,11 +58,11 @@ namespace ConfigGenerator { public byte ConnectionTimeout { get; set; } = DefaultConnectionTimeout; [JsonProperty] - public string CurrentCulture { get; set; } = null; + public string CurrentCulture { get; set; } [LocalizedCategory("Debugging")] [JsonProperty(Required = Required.DisallowNull)] - public bool Debug { get; set; } = false; + public bool Debug { get; set; } [LocalizedCategory("Performance")] [JsonProperty(Required = Required.DisallowNull)] @@ -74,7 +74,7 @@ namespace ConfigGenerator { [LocalizedCategory("Advanced")] [JsonProperty(Required = Required.DisallowNull)] - public bool Headless { get; set; } = false; + public bool Headless { get; set; } [LocalizedCategory("Performance")] [JsonProperty(Required = Required.DisallowNull)] @@ -104,7 +104,7 @@ namespace ConfigGenerator { [LocalizedCategory("Access")] [JsonProperty(Required = Required.DisallowNull)] - public ulong SteamOwnerID { get; set; } = 0; + public ulong SteamOwnerID { get; set; } [LocalizedCategory("Advanced")] [JsonProperty(Required = Required.DisallowNull)]