From cf870df3f88de1eefe971e94f804ff4f5a6c9554 Mon Sep 17 00:00:00 2001 From: Fahim Salam Chowdhury Date: Thu, 5 Sep 2024 16:02:45 +0600 Subject: [PATCH] fix: remove Nextcloud contacts app direct dependency on nextcloud plugin NC contacts app is just frontend for contacts & addressbook of NC server. Nextcloud plugin `auto save recipients on addressbook` feature used to depends on contacts app directly. This commit update that logic. --- plugins/nextcloud/NextcloudAddressBook.php | 3 ++- plugins/nextcloud/README.md | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/plugins/nextcloud/NextcloudAddressBook.php b/plugins/nextcloud/NextcloudAddressBook.php index 5e9f27c87..e418c6dfe 100644 --- a/plugins/nextcloud/NextcloudAddressBook.php +++ b/plugins/nextcloud/NextcloudAddressBook.php @@ -62,7 +62,8 @@ private function GetSavedAddressBookKey() : string public function IsSupported() : bool { // Maybe just return true, contacts app is just a frontend - return \OC::$server->getAppManager()->isEnabledForUser('contacts'); + // return \OC::$server->getAppManager()->isEnabledForUser('contacts'); + return true; } public function SetEmail(string $sEmail) : bool diff --git a/plugins/nextcloud/README.md b/plugins/nextcloud/README.md index fc2c6ed37..972e1cdc8 100644 --- a/plugins/nextcloud/README.md +++ b/plugins/nextcloud/README.md @@ -2,7 +2,7 @@ ## Nextcloud Addressbook for recipients -This plugin can let user to choose which nextcloud addressbook to use save recipients. This is opt-in feature (enabled by admin). After admin enable this, user will find a dropdown in his/her SnappyMail's `Contacts` section, containing all his/her addressbook. + This plugin can let user to choose which nextcloud addressbook to use save recipients. This is opt-in feature (enabled by admin). After admin enable this, user will find a dropdown in his/her SnappyMail's `Contacts` section, containing all his/her addressbook. It works better with [Nextcloud Contacts App](https://github.com/nextcloud/contacts/) ### Admin settings