From 3d36e8380648e231e8db1bb8410a47451b598776 Mon Sep 17 00:00:00 2001 From: Aleksander Machniak Date: Mon, 12 May 2014 14:25:49 +0200 Subject: Performance fix: don't send vcard/photo data to the browser after contact update --- program/steps/addressbook/save.inc | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'program/steps/addressbook') diff --git a/program/steps/addressbook/save.inc b/program/steps/addressbook/save.inc index 94556f96b..7451f433b 100644 --- a/program/steps/addressbook/save.inc +++ b/program/steps/addressbook/save.inc @@ -165,6 +165,10 @@ if (!empty($cid)) { $a_js_cols[] = rcube::Q((string)$record[$col]); } + // performance: unset some big data items we don't need here + $record = array_intersect_key($record, array('ID' => 1,'email' => 1,'name' => 1)); + $record['_type'] = 'person'; + // update the changed col in list $OUTPUT->command('parent.update_contact_row', $cid, $a_js_cols, $newcid, $source, $record); -- cgit v1.2.3