diff --git a/UndertaleModTool/Converters/CodeViewConverter.cs b/UndertaleModTool/Converters/CodeViewConverter.cs index 04e77b669..80c722031 100644 --- a/UndertaleModTool/Converters/CodeViewConverter.cs +++ b/UndertaleModTool/Converters/CodeViewConverter.cs @@ -14,7 +14,7 @@ protected override Predicate CreateFilter() return (obj) => { if (obj is UndertaleCode code && - code.ParentEntry != null && + code.ParentEntry is not null && Settings.Instance.HideChildCodeEntries) return false; return baseFilter(obj); diff --git a/UndertaleModTool/Converters/FilteredViewConverter.cs b/UndertaleModTool/Converters/FilteredViewConverter.cs index 73320d566..465217f14 100644 --- a/UndertaleModTool/Converters/FilteredViewConverter.cs +++ b/UndertaleModTool/Converters/FilteredViewConverter.cs @@ -45,7 +45,7 @@ protected virtual Predicate CreateFilter() public object Convert(object value, Type targetType, object parameter, CultureInfo culture) { - if (value == null) + if (value is null) return null; ICollectionView filteredView = CollectionViewSource.GetDefaultView(value); filteredView.Filter = CreateFilter();