From a3af9f4773ec498ca9049f8995bdfad912e0d3c8 Mon Sep 17 00:00:00 2001 From: Thomas Tanghus <thomas@tanghus.net> Date: Thu, 23 Aug 2012 14:45:19 +0200 Subject: [PATCH] Used non-existing variable. --- apps/contacts/lib/share/addressbook.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/contacts/lib/share/addressbook.php b/apps/contacts/lib/share/addressbook.php index 62799696d9..0c90470d37 100644 --- a/apps/contacts/lib/share/addressbook.php +++ b/apps/contacts/lib/share/addressbook.php @@ -41,7 +41,7 @@ class OC_Share_Backend_Addressbook implements OCP\Share_Backend_Collection { public function generateTarget($itemSource, $shareWith, $exclude = null) { $addressbook = OC_Contacts_Addressbook::find( $itemSource ); $user_addressbooks = array(); - foreach(OC_Contacts_Addressbook::all($uid) as $user_addressbook) { + foreach(OC_Contacts_Addressbook::all($shareWith) as $user_addressbook) { $user_addressbooks[] = $user_addressbook['displayname']; } $name = $addressbook['userid']."'s ".$addressbook['displayname']; @@ -49,7 +49,7 @@ class OC_Share_Backend_Addressbook implements OCP\Share_Backend_Collection { while (in_array($name.$suffix, $user_addressbooks)) { $suffix++; } - + return $name.$suffix; } -- GitLab