<?xml version="1.0" encoding="UTF-8"?> 
<?xml-stylesheet href="https://dev.horde.org/themes/horde//default/feed-rss.xsl" type="text/xsl"?> 
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"> 
 <channel> 
  <title>Cleanup default address book mess</title> 
  <pubDate>Thu, 09 Apr 2026 14:41:44 +0000</pubDate> 
  <link>https://bugs.horde.org/ticket/11773</link> 
  <atom:link rel="self" type="application/rss+xml" title="Cleanup default address book mess" href="https://bugs.horde.org/ticket/11773/rss" /> 
  <description>Cleanup default address book mess</description> 
 
   
   
  <item> 
   <title>We currently have 3 different ways to determine a default ad</title> 
   <description>We currently have 3 different ways to determine a default address book, some using each other, and used differently and different places.

1) default_dir preference
Only used in 2) and when importing contacts.
2) Turba_Api::getDefaultShare()
Only works on shares, looks for the &#039;default&#039; share parameter (only set by Kolab), but falls back to default_dir pref, which could be any, even non-share address book. Only place used is the hook example for IMP&#039;s &#039;add_source&#039; preference.
3) Turba::getDefaultAddressbook()
Simply picks the first share or the first of all address books, complete ignoring user preferences and is used in some API methods, as the default synchronization source, and to determine the initial address book after logging in.

It might make sense to have different defaults for general address book usage and for adding contacts, though:
- The default_dir pref mentions both adding and importing contacts, while it&#039;s only used for importing contacts.
- We don&#039;t do this in any other application. Granted, all other applications can display more than one source, so this makes Turba different.

Another problem: after (my) removal of the address book sorting and selection, there is no way anymore for the user to define the default address book (by moving it to the top of the list).

So my short-term suggestion is to use default_dir for all default address book selections, defaulting to whatever the backend provides as the default (Kolab), and falling back to the first of all available address books, with a priority to the user&#039;s own shares.</description> 
   <pubDate>Wed, 28 Nov 2012 13:41:18 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/11773#t75181</link> 
  </item> 
   
  <item> 
   <title>Any further opinions?</title> 
   <description>Any further opinions?</description> 
   <pubDate>Tue, 27 Aug 2013 10:47:45 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/11773#t80402</link> 
  </item> 
   
   
 
 </channel> 
</rss> 
