From 5f138e6a2ffe466b6c6bfdccca2937951dca80a3 Mon Sep 17 00:00:00 2001
From: Niko Ehrenfeuchter <nikolaus.ehrenfeuchter@unibas.ch>
Date: Mon, 16 Jul 2018 14:35:19 +0200
Subject: [PATCH] Revert "Remove existence check for TmpTransferDir"

Since we're now back on using a central location for storing temporary
transfer files, it does make sense again to check for that location to
exist on service startup (refers to #16).

This reverts commit 106407545158095a68751c4bafb089527dff0985.
---
 ATxCommon/Serializables/ServiceConfig.cs | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/ATxCommon/Serializables/ServiceConfig.cs b/ATxCommon/Serializables/ServiceConfig.cs
index 03e1ade..bf65c98 100644
--- a/ATxCommon/Serializables/ServiceConfig.cs
+++ b/ATxCommon/Serializables/ServiceConfig.cs
@@ -403,6 +403,11 @@ namespace ATxCommon.Serializables
             if (!Directory.Exists(c.DestinationDirectory))
                 errmsg += $"can't find (or reach) destination: {c.DestinationDirectory}\n";
 
+            // TmpTransferDir
+            var tmpTransferPath = Path.Combine(c.DestinationDirectory, c.TmpTransferDir);
+            if (!Directory.Exists(tmpTransferPath))
+                errmsg += $"can't find (or reach) temporary transfer dir: {tmpTransferPath}\n";
+
 
             ////////// OPTIONAL PARAMETERS SETTINGS VALIDATION //////////
 
-- 
GitLab