mirror of
https://github.com/JustArchiNET/ArchiSteamFarm.git
synced 2026-01-01 22:20:52 +00:00
Remove obsolete statistics mapping
This already skipped one monthly cycle, everybody who remotely cares to use up-to-date ASF is already migrated to proper config, everybody else is not making use of it either way
This commit is contained in:
@@ -35,7 +35,6 @@ using ArchiSteamFarm.IPC.Integration;
|
||||
using ArchiSteamFarm.Localization;
|
||||
using ArchiSteamFarm.Steam.Data;
|
||||
using ArchiSteamFarm.Steam.Integration;
|
||||
using ArchiSteamFarm.Storage;
|
||||
using JetBrains.Annotations;
|
||||
using Newtonsoft.Json;
|
||||
using Newtonsoft.Json.Linq;
|
||||
@@ -621,18 +620,7 @@ public sealed class BotConfig {
|
||||
break;
|
||||
}
|
||||
|
||||
// TODO: Pending removal, Statistics -> RemoteCommunication migration
|
||||
if ((ASF.GlobalConfig?.Statistics == false) && (botConfig.RemoteCommunication == DefaultRemoteCommunication)) {
|
||||
botConfig.RemoteCommunication = ERemoteCommunication.None;
|
||||
}
|
||||
|
||||
if (!Program.ConfigMigrate) {
|
||||
// TODO: Pending removal, warning for people that disabled config migrate, they need to migrate themselves
|
||||
if (ASF.GlobalConfig?.Statistics == false) {
|
||||
ASF.ArchiLogger.LogGenericWarning(string.Format(CultureInfo.CurrentCulture, Strings.WarningFailedWithError, nameof(Program.ConfigMigrate)));
|
||||
ASF.ArchiLogger.LogGenericWarning(string.Format(CultureInfo.CurrentCulture, Strings.WarningDeprecated, nameof(GlobalConfig.Statistics), nameof(RemoteCommunication)));
|
||||
}
|
||||
|
||||
return (botConfig, null);
|
||||
}
|
||||
|
||||
|
||||
@@ -297,10 +297,6 @@ public sealed class GlobalConfig {
|
||||
|
||||
internal bool Saving { get; set; }
|
||||
|
||||
// TODO: Pending removal, Statistics property which got changed into RemoteConnection
|
||||
[JsonProperty(Required = Required.DisallowNull)]
|
||||
internal bool Statistics { get; private set; } = true;
|
||||
|
||||
[JsonProperty]
|
||||
internal string? WebProxyPassword {
|
||||
get => BackingWebProxyPassword;
|
||||
@@ -396,12 +392,6 @@ public sealed class GlobalConfig {
|
||||
[UsedImplicitly]
|
||||
public bool ShouldSerializeSSteamOwnerID() => !Saving;
|
||||
|
||||
// TODO: Pending removal, Statistics property which got changed into RemoteConnection, we never serialize it after update
|
||||
#pragma warning disable CA1822 // We can't mark it as static
|
||||
[UsedImplicitly]
|
||||
public bool ShouldSerializeStatistics() => false;
|
||||
#pragma warning restore CA1822 // We can't mark it as static
|
||||
|
||||
[UsedImplicitly]
|
||||
public bool ShouldSerializeSteamMessagePrefix() => !Saving || (SteamMessagePrefix != DefaultSteamMessagePrefix);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user