-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable sharing calendars via link when sharing via link is disabled #34372
Conversation
This mod disallows sharing calendars via link when `shareapi_allow_links` is disabled. Related: nextcloud/calendar#525 Related: nextcloud/calendar#4399 Author-Change-Id: IB#1126264 Signed-off-by: Pawel Boguslawski <pawel.boguslawski@ib.pl>
This mod hides sharing calendar via link in UI when `shareapi_allow_links` is disabled. Should be applied together with nextcloud/server#34372 Related: nextcloud/server#34372 Related: nextcloud#525 Related: nextcloud#4399 Author-Change-Id: IB#1126264 Signed-off-by: Pawel Boguslawski <pawel.boguslawski@ib.pl>
Thanks for your PR! A couple small change requests only :) |
Fixes: 45eefc2 Related: nextcloud#34372 Author-Change-Id: IB#1126264 Signed-off-by: Pawel Boguslawski <pawel.boguslawski@ib.pl>
\OC::$server->getConfig(), | ||
\OC::$server->getURLGenerator() | ||
)); | ||
if (\OC::$server->getConfig()->getAppValue('core', 'shareapi_allow_links', 'yes') === 'yes') { |
Check notice
Code scanning / Psalm
DeprecatedMethod
)); | ||
if (\OC::$server->getConfig()->getAppValue('core', 'shareapi_allow_links', 'yes') === 'yes') { | ||
$this->server->addPlugin(new \OCA\DAV\CalDAV\Publishing\PublishPlugin( | ||
\OC::$server->getConfig(), |
Check notice
Code scanning / Psalm
DeprecatedMethod
if (\OC::$server->getConfig()->getAppValue('core', 'shareapi_allow_links', 'yes') === 'yes') { | ||
$this->server->addPlugin(new \OCA\DAV\CalDAV\Publishing\PublishPlugin( | ||
\OC::$server->getConfig(), | ||
\OC::$server->getURLGenerator() |
Check notice
Code scanning / Psalm
DeprecatedMethod
Current solution (unregistering plugin) does not work correctly so please wait with merging until final solution is proposed. |
@pboguslawski That's correct, thanks for checking! Sadly the AllowedSharingModes didn't fallback as I planned when the plugin was unregistered, so I made #34873 to extract exposing this information into it's own plugin. That should do it, please have a go and test. |
Replaced with #34873. |
This mod disallows sharing calendars via link when
shareapi_allow_links
is disabled.Related: nextcloud/calendar#525
Related: nextcloud/calendar#4399
Author-Change-Id: IB#1126264
Signed-off-by: Pawel Boguslawski pawel.boguslawski@ib.pl