Add some logging, fix som bugs

This commit is contained in:
Ottermandias 2023-04-15 20:38:02 +02:00
parent 85fb98b557
commit 9037166d92
12 changed files with 58 additions and 41 deletions

View file

@ -743,7 +743,7 @@ public class ItemSwapTab : IDisposable, ITab
private void OnCollectionChange(CollectionType collectionType, ModCollection? oldCollection,
ModCollection? newCollection, string _)
{
if (collectionType != CollectionType.Current || _mod == null || newCollection == null)
if (collectionType is not CollectionType.Current || _mod == null || newCollection == null)
return;
UpdateMod(_mod, _mod.Index < newCollection.Settings.Count ? newCollection[_mod.Index].Settings : null);