Code inspection: Dictionary lookup can be simplified with 'GetValueOrDefault'

Last modified: 04 June 2024

If you use the Dictionary.TryGetValue() method and fall back to some default value if the key is not found, JetBrains Rider suggest using the dedicated CollectionExtensions.GetValueOrDefault() method instead to improve the structure and readability of your code.