From e409a04789f4af6ea15c241a5a81f52041cfd645 Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Tue, 5 Feb 2008 09:34:56 +0000 Subject: [PATCH] fix traceback when opening features window. fixes #3714 --- src/features_window.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/features_window.py b/src/features_window.py index 59c5f3a1f..a57822959 100644 --- a/src/features_window.py +++ b/src/features_window.py @@ -142,7 +142,10 @@ class FeaturesWindow: selection = widget.get_selection() if not selection: return - path = selection.get_selected_rows()[1][0] + rows = selection.get_selected_rows()[1] + if not rows: + return + path = rows[0] available = self.model[path][1] feature = self.model[path][0].decode('utf-8') text = self.features[feature][1] + '\n'