From 53aa02669cd5c40f7c33bd293c30d2836cbc02c3 Mon Sep 17 00:00:00 2001 From: marcel Date: Fri, 18 Aug 2017 11:36:58 +0200 Subject: [PATCH] [bugfix] savepath overwritten after first occurrence in for loop --- autoPyLoT.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/autoPyLoT.py b/autoPyLoT.py index 9c9d9a03..3ef69712 100755 --- a/autoPyLoT.py +++ b/autoPyLoT.py @@ -414,8 +414,10 @@ def autoPyLoT(input_dict=None, parameter=None, inputfile=None, fnames=None, even data.applyEVTData(picks) if savexml: if savepath == 'None' or savepath == None: - savepath = eventpath - fnqml = '%s/PyLoT_%s' % (savepath, evID) + saveEvtPath = eventpath + else: + saveEvtPath = savepath + fnqml = '%s/PyLoT_%s' % (saveEvtPath, evID) data.exportEvent(fnqml, fnext='.xml', fcheck=['auto', 'magnitude', 'origin']) if locflag == 1: # HYPO71