Added seperate collections for other states, moved clean up of penumbra collection out of config. Safe read of ptr on process, fixed notfications on popup and notifications with flags.
This commit is contained in:
@@ -213,7 +213,7 @@ public sealed partial class FileCompactor : IDisposable
|
||||
/// <param name="bytes">Bytes that have to be written</param>
|
||||
/// <param name="token">Cancellation Token for interupts</param>
|
||||
/// <returns>Writing Task</returns>
|
||||
public async Task WriteAllBytesAsync(string filePath, byte[] bytes, CancellationToken token)
|
||||
public async Task WriteAllBytesAsync(string filePath, byte[] bytes, CancellationToken token, bool enqueueCompaction = true)
|
||||
{
|
||||
var dir = Path.GetDirectoryName(filePath);
|
||||
if (!string.IsNullOrEmpty(dir) && !Directory.Exists(dir))
|
||||
@@ -221,6 +221,12 @@ public sealed partial class FileCompactor : IDisposable
|
||||
|
||||
await File.WriteAllBytesAsync(filePath, bytes, token).ConfigureAwait(false);
|
||||
|
||||
if (enqueueCompaction && _lightlessConfigService.Current.UseCompactor)
|
||||
EnqueueCompaction(filePath);
|
||||
}
|
||||
|
||||
public void RequestCompaction(string filePath)
|
||||
{
|
||||
if (_lightlessConfigService.Current.UseCompactor)
|
||||
EnqueueCompaction(filePath);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user