diff --git a/FreeTubeSyncer/REST/Syncer.cs b/FreeTubeSyncer/REST/Syncer.cs index b92c4ed..0726331 100644 --- a/FreeTubeSyncer/REST/Syncer.cs +++ b/FreeTubeSyncer/REST/Syncer.cs @@ -218,8 +218,9 @@ public class Syncer : ISyncer where T : class, IDataModel, new() foreach (var line in json) fh.Write(Encoding.UTF8.GetBytes(line + "\n")); fh.Flush(); - fh.Close(); } + + Task.Delay(100).Wait(); _watcher.Locked = false; Log.Information("Updated {DbName}, completed in {TimeSpan}", _dbName, DateTime.Now - start); _isDirty = false;