Fix invalid API call when manipulating multiple mods at once.

This commit is contained in:
Ottermandias 2022-07-04 11:10:10 +02:00
parent 7a3c23d8c9
commit 0ce41f82a6

View file

@ -628,7 +628,7 @@ public class PenumbraApi : IDisposable, IPenumbraApi
var name = c.Name;
void Del( ModSettingChange type, int idx, int _, int _2, bool inherited )
=> ModSettingChanged?.Invoke( type, name, Penumbra.ModManager[ idx ].ModPath.Name, inherited );
=> ModSettingChanged?.Invoke( type, name, idx >= 0 ? Penumbra.ModManager[ idx ].ModPath.Name : string.Empty, inherited );
_delegates[ c ] = Del;
c.ModSettingChanged += Del;