From c163bfc18e7950e8819cf274d56eee328b6a9f92 Mon Sep 17 00:00:00 2001 From: SNoiraud Date: Wed, 10 Feb 2016 17:40:25 +0100 Subject: [PATCH] 9094: Double-clicking on a source causes exception : better solution. --- gramps/plugins/gramplet/citations.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gramps/plugins/gramplet/citations.py b/gramps/plugins/gramplet/citations.py index d2bb12569..1e69aa228 100644 --- a/gramps/plugins/gramplet/citations.py +++ b/gramps/plugins/gramplet/citations.py @@ -246,8 +246,8 @@ class Citations(Gramplet, DbGUIElement): # bug 9094. # str(model.get_path(iter_)) return something like NNN:MMM # So if we have only NNN, it's a node - path = str(model.get_path(iter_)) - if path.find(':') == -1: # we don't have ':' in the returned string. + # removing the str() solves the problem. + if len(model.get_path(iter_)) == 1: self.edit_source(handle) else: self.edit_citation(handle)