From 5f8569c7d9aa1c35fc6c90378bbbe33804b47cf4 Mon Sep 17 00:00:00 2001 From: Sebastian Wehling-Benatelli Date: Mon, 30 Nov 2015 09:53:55 +0100 Subject: [PATCH] [bugfix] now catching all cases --- pylot/core/util/widgets.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pylot/core/util/widgets.py b/pylot/core/util/widgets.py index 16731ef3..1f9a318b 100644 --- a/pylot/core/util/widgets.py +++ b/pylot/core/util/widgets.py @@ -611,13 +611,15 @@ class PickDlg(QDialog): phase_col = {'P': ('c', 'c--', 'b-'), 'S': ('m', 'm--', 'r-')} if self.getPicks(): - if phase is not None: + if phase is not None and type(self.getPicks()[phase]) is dict: picks = self.getPicks()[phase] colors = phase_col[phase[0].upper()] - else: + elif phase is None: for phase in self.getPicks(): self.drawPicks(phase) return + else: + return else: return