From be08e5094f81e7e73b2936c1b52fa4563d051061 Mon Sep 17 00:00:00 2001 From: Manuel Reinhardt Date: Fri, 12 Jul 2019 14:12:11 +0200 Subject: [PATCH] Principals: don't merge titles. The first one is the one from the plugin with the highest priority. --- plone/app/vocabularies/principals.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/plone/app/vocabularies/principals.py b/plone/app/vocabularies/principals.py index ece63f3..49afebd 100644 --- a/plone/app/vocabularies/principals.py +++ b/plone/app/vocabularies/principals.py @@ -69,9 +69,11 @@ def merge_principal_infos(infos, prefix=False): # Principals with the same ID but different types. Should not # happen. raise ValueError('Principal ID not unique: {}'.format(info['id'])) - info['title'] = ';'.join( - [info['title'] for info in infos if info['title']] - ) + if not info['title']: + for candidate in infos: + if candidate['title']: + info['title'] = candidate['title'] + break return info