From c684db300082dd460fa7964d32a8d53a33ff989d Mon Sep 17 00:00:00 2001 From: Ottermandias Date: Thu, 5 Jan 2023 15:57:18 +0100 Subject: [PATCH] Small security check. --- Penumbra/UI/Classes/ItemSwapWindow.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Penumbra/UI/Classes/ItemSwapWindow.cs b/Penumbra/UI/Classes/ItemSwapWindow.cs index 8dbab3e8..b086e148 100644 --- a/Penumbra/UI/Classes/ItemSwapWindow.cs +++ b/Penumbra/UI/Classes/ItemSwapWindow.cs @@ -652,7 +652,7 @@ public class ItemSwapWindow : IDisposable return; } - UpdateMod( _mod, newCollection.Settings[ _mod.Index ] ); + UpdateMod( _mod, _mod.Index < newCollection.Settings.Count ? newCollection.Settings[ _mod.Index ] : null ); newCollection.ModSettingChanged += OnSettingChange; if( oldCollection != null ) {