why did this even crash to begin with

This commit is contained in:
Stanley Dimant
2025-02-10 20:54:05 +01:00
parent b7b79e6e1d
commit 79f5065128

View File

@@ -88,16 +88,21 @@ public sealed class TransientResourceManager : DisposableMediatorSubscriberBase
return; return;
} }
bool removedPaths = false;
foreach (var replacement in fileReplacement.Where(p => !p.HasFileReplacement).SelectMany(p => p.GamePaths).ToList()) foreach (var replacement in fileReplacement.Where(p => !p.HasFileReplacement).SelectMany(p => p.GamePaths).ToList())
{ {
removedPaths = true;
PlayerConfig.RemovePath(replacement); PlayerConfig.RemovePath(replacement);
} }
if (removedPaths)
{
// force reload semi transient resources // force reload semi transient resources
_semiTransientResources = null; _semiTransientResources = null;
_configurationService.Save(); _configurationService.Save();
} }
} }
}
public HashSet<string> GetSemiTransientResources(ObjectKind objectKind) public HashSet<string> GetSemiTransientResources(ObjectKind objectKind)
{ {