Address latest Rider code inspections

This commit is contained in:
Łukasz Domeradzki
2024-04-11 23:24:01 +02:00
parent e18e1533e3
commit 0ccec4c8c1
4 changed files with 49 additions and 44 deletions

View File

@@ -122,7 +122,7 @@ internal static class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => ResponseMatch(Steam.Interaction.Commands.GetProxyAccess(bot, access, steamID), bot)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}

View File

@@ -199,7 +199,7 @@ internal static class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => ResponseTwoFactorFinalize(Steam.Interaction.Commands.GetProxyAccess(bot, access, steamID), bot, activationCode))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -292,7 +292,7 @@ internal static class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => ResponseTwoFactorFinalized(Steam.Interaction.Commands.GetProxyAccess(bot, access, steamID), bot, activationCode))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -371,7 +371,7 @@ internal static class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => ResponseTwoFactorInit(Steam.Interaction.Commands.GetProxyAccess(bot, access, steamID), bot))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}

View File

@@ -765,6 +765,10 @@ limitations under the License.</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateInstanceFields/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="" Suffix="" Style="AaBb" /&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateStaticFields/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="" Suffix="" Style="AaBb" /&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=TypeParameters/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="T" Suffix="" Style="AaBb" /&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/UserRules/=236f7aa5_002D7b06_002D43ca_002Dbf2a_002D9b31bfcff09a/@EntryIndexedValue">&lt;Policy&gt;&lt;Descriptor Staticness="Any" AccessRightKinds="Private" Description="Constant fields (private)"&gt;&lt;ElementKinds&gt;&lt;Kind Name="CONSTANT_FIELD" /&gt;&lt;/ElementKinds&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="AaBb"&gt;&lt;ExtraRule Prefix="I" Suffix="" Style="AaBb" /&gt;&lt;/Policy&gt;&lt;/Policy&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/UserRules/=2c62818f_002D621b_002D4425_002Dadc9_002D78611099bfcb/@EntryIndexedValue">&lt;Policy&gt;&lt;Descriptor Staticness="Any" AccessRightKinds="Any" Description="Type parameters"&gt;&lt;ElementKinds&gt;&lt;Kind Name="TYPE_PARAMETER" /&gt;&lt;/ElementKinds&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="T" Suffix="" Style="AaBb" /&gt;&lt;/Policy&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/UserRules/=4a98fdf6_002D7d98_002D4f5a_002Dafeb_002Dea44ad98c70c/@EntryIndexedValue">&lt;Policy&gt;&lt;Descriptor Staticness="Instance" AccessRightKinds="Private" Description="Instance fields (private)"&gt;&lt;ElementKinds&gt;&lt;Kind Name="FIELD" /&gt;&lt;Kind Name="READONLY_FIELD" /&gt;&lt;/ElementKinds&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="AaBb" /&gt;&lt;/Policy&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/UserRules/=f9fce829_002De6f4_002D4cb2_002D80f1_002D5497c44f51df/@EntryIndexedValue">&lt;Policy&gt;&lt;Descriptor Staticness="Static" AccessRightKinds="Private" Description="Static fields (private)"&gt;&lt;ElementKinds&gt;&lt;Kind Name="FIELD" /&gt;&lt;/ElementKinds&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="AaBb" /&gt;&lt;/Policy&gt;</s:String>
<s:String x:Key="/Default/CustomTools/CustomToolsData/@EntryValue"></s:String>
<s:Boolean x:Key="/Default/Environment/Highlighting/HighlightingEnabled/@EntryValue">True</s:Boolean>
<s:String x:Key="/Default/Environment/Highlighting/HighlightingMode/@EntryValue">OnlyMarkers</s:String>
@@ -812,6 +816,7 @@ limitations under the License.</s:String>
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002ECSharpPlaceAttributeOnSameLineMigration/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EMigrateBlankLinesAroundFieldToBlankLinesAroundProperty/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EMigrateThisQualifierSettings/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EPredefinedNamingRulesToUserRulesUpgrade/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002EFormat_002ESettingsUpgrade_002EAlignmentTabFillStyleMigration/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002EJavaScript_002ECodeStyle_002ESettingsUpgrade_002EJsParsFormattingSettingsUpgrader/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002EJavaScript_002ECodeStyle_002ESettingsUpgrade_002EJsWrapperSettingsUpgrader/@EntryIndexedValue">True</s:Boolean>

View File

@@ -541,7 +541,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.Response2FA(GetProxyAccess(bot, access, steamID)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -583,7 +583,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.Response2FAConfirm(GetProxyAccess(bot, access, steamID), confirm))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -689,7 +689,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseAddLicense(GetProxyAccess(bot, access, steamID), query))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -740,7 +740,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseAdvancedLoot(GetProxyAccess(bot, access, steamID), appID, contextID))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -832,7 +832,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseAdvancedRedeem(GetProxyAccess(bot, access, steamID), options, keys, steamID))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -921,7 +921,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseAdvancedTransfer(GetProxyAccess(bot, access, steamID), appID, contextID, targetBot))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -955,7 +955,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseBackgroundGamesRedeemer(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1032,7 +1032,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseFarm(GetProxyAccess(bot, access, steamID)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1060,7 +1060,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseFarmingBlacklist(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1124,7 +1124,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseFarmingBlacklistAdd(GetProxyAccess(bot, access, steamID), targetAppIDs)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1183,7 +1183,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseFarmingBlacklistRemove(GetProxyAccess(bot, access, steamID), targetAppIDs)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1211,7 +1211,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseFarmingQueue(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1282,7 +1282,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseFarmingQueueAdd(GetProxyAccess(bot, access, steamID), targetAppIDs)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1346,7 +1346,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseFarmingQueueRemove(GetProxyAccess(bot, access, steamID), targetAppIDs)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1424,7 +1424,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseInput(GetProxyAccess(bot, access, steamID), propertyName, inputValue)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1462,7 +1462,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseLevel(GetProxyAccess(bot, access, steamID)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1504,7 +1504,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseLoot(GetProxyAccess(bot, access, steamID)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1565,7 +1565,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseLootByRealAppIDs(GetProxyAccess(bot, access, steamID), realAppIDsText, exclude))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1593,7 +1593,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseMatchActivelyBlacklist(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1644,7 +1644,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseMatchActivelyBlacklistAdd(GetProxyAccess(bot, access, steamID), targetAppIDs)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1695,7 +1695,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseMatchActivelyBlacklistRemove(GetProxyAccess(bot, access, steamID), targetAppIDs)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1739,7 +1739,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseNickname(GetProxyAccess(bot, access, steamID), nickname)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -1907,7 +1907,7 @@ public sealed class Commands {
IList<(string? Response, Dictionary<string, string>? OwnedGames)> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseOwns(GetProxyAccess(bot, access, steamID), query))).ConfigureAwait(false);
List<(string Response, Dictionary<string, string> OwnedGames)> validResults = [..results.Where(static result => !string.IsNullOrEmpty(result.Response) && (result.OwnedGames != null))];
List<(string Response, Dictionary<string, string> OwnedGames)> validResults = [..results.Where(static result => !string.IsNullOrEmpty(result.Response) && (result.OwnedGames != null))!];
if (validResults.Count == 0) {
return null;
@@ -1971,7 +1971,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponsePause(GetProxyAccess(bot, access, steamID), permanent, resumeInSecondsText))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2061,7 +2061,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponsePlay(GetProxyAccess(bot, access, steamID), targetGameIDs))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2099,7 +2099,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponsePointsBalance(GetProxyAccess(bot, access, steamID)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2252,7 +2252,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponsePrivacy(GetProxyAccess(bot, access, steamID), privacySettingsText))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2532,7 +2532,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseRedeem(GetProxyAccess(bot, access, steamID), keysText, steamID, redeemFlags))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2570,7 +2570,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseReset(GetProxyAccess(bot, access, steamID)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2618,7 +2618,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseResume(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2652,7 +2652,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseStart(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2729,7 +2729,7 @@ public sealed class Commands {
IList<(string? Response, Bot Bot)> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseStatus(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<(string Response, Bot Bot)> validResults = [..results.Where(static result => !string.IsNullOrEmpty(result.Response))];
List<(string Response, Bot Bot)> validResults = [..results.Where(static result => !string.IsNullOrEmpty(result.Response))!];
if (validResults.Count == 0) {
return null;
@@ -2771,7 +2771,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseStop(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2799,7 +2799,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseTradingBlacklist(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2850,7 +2850,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseTradingBlacklistAdd(GetProxyAccess(bot, access, steamID), targetSteamIDs)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2901,7 +2901,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseTradingBlacklistRemove(GetProxyAccess(bot, access, steamID), targetSteamIDs)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -2960,7 +2960,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseTransfer(GetProxyAccess(bot, access, steamID), botNameTo))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -3077,7 +3077,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseTransferByRealAppIDs(GetProxyAccess(bot, access, steamID), realAppIDs, targetBot, exclude))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -3141,7 +3141,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => bot.Commands.ResponseUnpackBoosters(GetProxyAccess(bot, access, steamID)))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}
@@ -3252,7 +3252,7 @@ public sealed class Commands {
IList<string?> results = await Utilities.InParallel(bots.Select(bot => Task.Run(() => bot.Commands.ResponseWalletBalance(GetProxyAccess(bot, access, steamID))))).ConfigureAwait(false);
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))];
List<string> responses = [..results.Where(static result => !string.IsNullOrEmpty(result))!];
return responses.Count > 0 ? string.Join(Environment.NewLine, responses) : null;
}