Move `IoHelpers.EnsureDirectoryExists()` from `BitcoinStore` to `AllTransactionStore` and `IndexStore` classes
MODIFY
WalletWasabi/Blockchain/Transactions/AllTransactionStore.cs
WalletWasabi/Blockchain/Transactions/AllTransactionStore.cs
@@ -33,7 +33,7 @@ namespace WalletWasabi.Blockchain.Transactions
using (BenchmarkLogger.Measure())
{
WorkFolderPath = Guard.NotNullOrEmptyOrWhitespace(nameof(workFolderPath), workFolderPath, trim: true);
-
+ IoHelpers.EnsureDirectoryExists(WorkFolderPath);
MempoolStore = new TransactionStore();
ConfirmedStore = new TransactionStore();
Lock = new object();

MODIFY
WalletWasabi/Stores/BitcoinStore.cs
WalletWasabi/Stores/BitcoinStore.cs
@@ -27,7 +27,6 @@ namespace WalletWasabi.Stores
MempoolService mempoolService)
{
var workFolderPath2 = Guard.NotNullOrEmptyOrWhitespace(nameof(workFolderPath), workFolderPath, trim: true);
- IoHelpers.EnsureDirectoryExists(workFolderPath2);
NetworkWorkFolderPath = Path.Combine(workFolderPath2, network.ToString());
IndexStoreFolderPath = Path.Combine(NetworkWorkFolderPath, "IndexStore");

MODIFY
WalletWasabi/Stores/IndexStore.cs
WalletWasabi/Stores/IndexStore.cs
@@ -51,6 +51,7 @@ namespace WalletWasabi.Stores
using (BenchmarkLogger.Measure())
{
WorkFolderPath = Guard.NotNullOrEmptyOrWhitespace(nameof(workFolderPath), workFolderPath, trim: true);
+ IoHelpers.EnsureDirectoryExists(WorkFolderPath);
var indexFilePath = Path.Combine(WorkFolderPath, "MatureIndex.dat");
MatureIndexFileManager = new DigestableSafeMutexIoManager(indexFilePath, digestRandomIndex: -1);
var immatureIndexFilePath = Path.Combine(WorkFolderPath, "ImmatureIndex.dat");

Move `IoHelpers.EnsureDirectoryExists()` from `BitcoinStore` to `AllTransactionStore` and `IndexStore` classes

(cherry picked from commit 2c63497638a3550dd1500db21f429a161f0943df)