Fix CA1841
This commit is contained in:
@@ -741,6 +741,9 @@ dotnet_diagnostic.CA1839.severity = warning
|
||||
# Use Environment.CurrentManagedThreadId instead of Thread.CurrentThread.ManagedThreadId.
|
||||
dotnet_diagnostic.CA1840.severity = warning
|
||||
|
||||
# Prefer Dictionary Contains methods.
|
||||
dotnet_diagnostic.CA1841.severity = warning
|
||||
|
||||
# Do not use 'WhenAll' with a single task.
|
||||
dotnet_diagnostic.CA1842.severity = warning
|
||||
|
||||
|
||||
@@ -66,7 +66,7 @@ namespace OpenRA.Mods.Common.Lint
|
||||
if (string.IsNullOrEmpty(voice))
|
||||
continue;
|
||||
|
||||
if (!soundInfo.Voices.Keys.Contains(voice))
|
||||
if (!soundInfo.Voices.ContainsKey(voice))
|
||||
emitError($"Actor {actorInfo.Name} using voice set {voiceSet} does not define {voice} voice required by {traitInfo}.");
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user