void IMarketDataStorageDrive.Delete(DateTime date) { date = date.UtcKind(); var path = GetPath(date, true); if (File.Exists(path)) { File.Delete(path); var dir = GetDirectoryName(path); if (Directory.EnumerateFiles(dir).IsEmpty()) { lock (_cacheSync) IOHelper.BlockDeleteDir(dir); } } var dates = DatesDict; dates.Remove(date); SaveDates(Dates.ToArray()); _availableDataTypes.Remove(_drive.Path); }