Bugfix where not giving origin with taupy would still use negative starttime

This commit is contained in:
Darius Arnold 2018-07-03 13:55:51 +02:00
parent 80835bc56e
commit 59e67b51d5

View File

@ -393,7 +393,7 @@ class AutopickStation(object):
' origin time using TauPy'.format(estFirstP, estFirstS)) ' origin time using TauPy'.format(estFirstP, estFirstS))
return estFirstP, estFirstS return estFirstP, estFirstS
if self.p_params.use_taup is False and self.p_params.pstart < 0: if (self.p_params.use_taup is False or not self.origin) and self.p_params.pstart < 0:
# correct user mistake where a relative cuttime is selected (pstart < 0) but use of taupy is disabled/ has # correct user mistake where a relative cuttime is selected (pstart < 0) but use of taupy is disabled/ has
# not the required parameters # not the required parameters
self.p_params.pstart = 0 self.p_params.pstart = 0