From f939041ad464d0249cb5cf2b34f273674c7cd7c0 Mon Sep 17 00:00:00 2001 From: Bastian Schroll Date: Fri, 15 May 2015 21:00:14 +0200 Subject: [PATCH] error in path check --- boswatch.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/boswatch.py b/boswatch.py index cade945..9a663f6 100644 --- a/boswatch.py +++ b/boswatch.py @@ -44,10 +44,11 @@ try: #Clear the Logfiles try: - if not os.path.isdir(script_path+"/log"): - os.mkdir(script_path+"/log") - script_path = os.path.dirname(os.path.abspath(__file__)) + + if not os.path.exists(script_path+"/log/"): + os.mkdir(script_path+"/log/") + bos_log = open(script_path+"/log/log_bos.txt", "w") rtl_log = open(script_path+"/log/log_rtl.txt", "w") mon_log = open(script_path+"/log/log_mon.txt", "w")