mirror of
https://github.com/Caraxi/mare.client.git
synced 2025-12-12 22:17:22 +01:00
fix minor FSW issues
This commit is contained in:
parent
656ee6a419
commit
a245e58944
2 changed files with 12 additions and 3 deletions
|
|
@ -108,15 +108,18 @@ public sealed class CacheMonitor : DisposableMediatorSubscriberBase
|
|||
| NotifyFilters.DirectoryName
|
||||
| NotifyFilters.Size,
|
||||
Filter = "*.*",
|
||||
IncludeSubdirectories = false
|
||||
IncludeSubdirectories = false,
|
||||
};
|
||||
|
||||
MareWatcher.Deleted += MareWatcher_FileChanged;
|
||||
MareWatcher.Created += MareWatcher_FileChanged;
|
||||
MareWatcher.EnableRaisingEvents = true;
|
||||
}
|
||||
|
||||
private void MareWatcher_FileChanged(object sender, FileSystemEventArgs e)
|
||||
{
|
||||
Logger.LogTrace("Mare FSW: FileChanged: {change} => {path}", e.ChangeType, e.FullPath);
|
||||
|
||||
if (!_allowedExtensions.Any(ext => e.FullPath.EndsWith(ext, StringComparison.OrdinalIgnoreCase))) return;
|
||||
|
||||
lock (_watcherChanges)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue