[Pkg-owncloud-commits] [php-sabredav] 99/220: It doesn't make sense to show the share UI for non-shareable nodes.

David Prévot taffit at moszumanska.debian.org
Thu May 12 01:21:13 UTC 2016


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository php-sabredav.

commit 3979e4c1c24ba3cc0295b43a4ce19d0284f20710
Author: Evert Pot <me at evertpot.com>
Date:   Wed Mar 23 01:35:46 2016 -0400

    It doesn't make sense to show the share UI for non-shareable nodes.
---
 lib/DAV/Sharing/Plugin.php | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/lib/DAV/Sharing/Plugin.php b/lib/DAV/Sharing/Plugin.php
index e9af465..10bea95 100644
--- a/lib/DAV/Sharing/Plugin.php
+++ b/lib/DAV/Sharing/Plugin.php
@@ -250,6 +250,10 @@ class Plugin extends ServerPlugin {
      */
     function htmlActionsPanel(INode $node, &$output, $path) {
 
+        if (!$node instanceof ISharedNode) {
+            return;
+        }
+
         $aclPlugin = $this->server->getPlugin('acl');
         if ($aclPlugin) {
           if (!$aclPlugin->checkPrivileges($path, '{DAV:}share', \Sabre\DAVACL\Plugin::R_PARENT, false)) {

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-php/php-sabredav.git



More information about the Pkg-owncloud-commits mailing list