summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrédéric Péters <fpeters@0d.be>2011-12-09 15:59:54 (GMT)
committerFrédéric Péters <fpeters@0d.be>2011-12-09 15:59:54 (GMT)
commit4f89307607896021b6ae1976d846df23ae118e09 (patch)
tree731f38e35375ddbdaf4a249b687461cd2d6fcffe
parent7b2cd85b3c391071d66b14b17e9acde1080a355f (diff)
downloadtabellio.searchform-4f89307607896021b6ae1976d846df23ae118e09.zip
tabellio.searchform-4f89307607896021b6ae1976d846df23ae118e09.tar.gz
tabellio.searchform-4f89307607896021b6ae1976d846df23ae118e09.tar.bz2
do not append twice the same person
-rw-r--r--tabellio/searchform/form.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/tabellio/searchform/form.py b/tabellio/searchform/form.py
index ebff639..acedf81 100644
--- a/tabellio/searchform/form.py
+++ b/tabellio/searchform/form.py
@@ -85,6 +85,7 @@ class ListAuthorsView(BrowserView):
for name_part in re.split(r'[-\s]', normalizer.normalize(object.Title()).lower()):
if name_part.startswith(q):
s.append(object)
+ break
def cmp_deputy(x, y):
return cmp(normalizer.normalize(x.Title()).lower(),
normalizer.normalize(y.Title()).lower())