1
0
mirror of https://github.com/owncloudarchive/contacts.git synced 2025-01-30 19:52:17 +01:00

Contacts: Register sharing backend even it not logged in.

This commit is contained in:
Thomas Tanghus 2013-03-15 11:48:33 +01:00
parent 5a7b1d4baa
commit 7401fbc947

View File

@ -26,11 +26,11 @@ OCP\App::addNavigationEntry( array(
OCP\Util::addscript('contacts', 'loader');
if(OCP\User::isLoggedIn()) {
OC_Search::registerProvider('OCA\Contacts\SearchProvider');
OCP\Share::registerBackend('contact', 'OCA\Contacts\Share_Backend_Contact');
OCP\Share::registerBackend('addressbook', 'OCA\Contacts\Share_Backend_Addressbook', 'contact');
OC_Search::registerProvider('OCA\Contacts\SearchProvider');
OCP\Share::registerBackend('contact', 'OCA\Contacts\Share_Backend_Contact');
OCP\Share::registerBackend('addressbook', 'OCA\Contacts\Share_Backend_Addressbook', 'contact');
if(OCP\User::isLoggedIn()) {
foreach(OCA\Contacts\Addressbook::all(OCP\USER::getUser()) as $addressbook) {
OCP\Contacts::registerAddressBook(new OCA\Contacts\AddressbookProvider($addressbook['id']));
}