From baecd8becccd7786632c1cda895123293ceb1408 Mon Sep 17 00:00:00 2001
From: Thomas Bruederli <thomas@roundcube.net>
Date: Thu, 26 Jul 2012 11:18:38 -0400
Subject: [PATCH] Move the hard-coded list of fields used to list contacts to a central location

---
 program/steps/mail/list_contacts.inc |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/program/steps/mail/list_contacts.inc b/program/steps/mail/list_contacts.inc
index 1a64803..7c99a13 100644
--- a/program/steps/mail/list_contacts.inc
+++ b/program/steps/mail/list_contacts.inc
@@ -57,7 +57,8 @@
 
     // get contacts for this user
     $CONTACTS->set_group(0);
-    $result = $CONTACTS->list_records(array('name', 'firstname', 'surname', 'email'));
+    $afields = $RCMAIL->config->get('contactlist_fields');
+    $result = $CONTACTS->list_records($afields);
 
     if (!$result->count && $result->searchonly) {
         $OUTPUT->show_message('contactsearchonly', 'notice');

--
Gitblit v1.9.1