mirror of
https://github.com/claunia/SabreTools.git
synced 2025-12-16 19:14:27 +00:00
Add null check to ShouldIgnore
This commit is contained in:
@@ -546,6 +546,13 @@ namespace SabreTools.DatFiles
|
||||
/// <returns>True if the item should be skipped on write, false otherwise</returns>
|
||||
protected bool ShouldIgnore(DatItem datItem, bool ignoreBlanks)
|
||||
{
|
||||
// If this is invoked with a null DatItem, we ignore
|
||||
if (datItem == null)
|
||||
{
|
||||
logger?.Verbose($"Item was skipped because it was null");
|
||||
return true;
|
||||
}
|
||||
|
||||
// If the item is supposed to be removed, we ignore
|
||||
if (datItem.Remove)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user