diff options
author | Arthur Schiwon <blizzz@arthur-schiwon.de> | 2016-06-11 15:34:43 +0200 |
---|---|---|
committer | Arthur Schiwon <blizzz@arthur-schiwon.de> | 2016-06-11 15:34:43 +0200 |
commit | 42c66efea5ef512d3a3442112f820168e6499265 (patch) | |
tree | 97ef44632d653656608e71e096fd537bbd609936 /apps/dav/appinfo | |
parent | 75f37f550bb7895757325d3f9a3215bcc4471065 (diff) | |
parent | 52a0c939ab8674857bbfe9a9fb0ee7308eee960e (diff) | |
download | nextcloud-server-42c66efea5ef512d3a3442112f820168e6499265.tar.gz nextcloud-server-42c66efea5ef512d3a3442112f820168e6499265.zip |
Merge branch 'master' of https://github.com/owncloud/core into downstream-160611
Diffstat (limited to 'apps/dav/appinfo')
-rw-r--r-- | apps/dav/appinfo/database.xml | 6 | ||||
-rw-r--r-- | apps/dav/appinfo/info.xml | 7 | ||||
-rw-r--r-- | apps/dav/appinfo/v1/publicwebdav.php | 9 |
3 files changed, 15 insertions, 7 deletions
diff --git a/apps/dav/appinfo/database.xml b/apps/dav/appinfo/database.xml index f79ea07ae76..9578526a705 100644 --- a/apps/dav/appinfo/database.xml +++ b/apps/dav/appinfo/database.xml @@ -272,6 +272,12 @@ CREATE TABLE calendarobjects ( <type>text</type> <length>255</length> </field> + <field> + <comments>0 - public, 1 - private, 2 - confidential</comments> + <name>classification</name> + <type>integer</type> + <default>0</default> + </field> <index> <name>calobjects_index</name> <unique>true</unique> diff --git a/apps/dav/appinfo/info.xml b/apps/dav/appinfo/info.xml index ca456b03089..26e37e6bb86 100644 --- a/apps/dav/appinfo/info.xml +++ b/apps/dav/appinfo/info.xml @@ -5,7 +5,7 @@ <description>ownCloud WebDAV endpoint</description> <licence>AGPL</licence> <author>owncloud.org</author> - <version>0.2.4</version> + <version>0.2.5</version> <default_enable/> <types> <filesystem/> @@ -20,4 +20,9 @@ <background-jobs> <job>OCA\DAV\CardDAV\Sync\SyncJob</job> </background-jobs> + <repair-steps> + <post-migration> + <job>OCA\DAV\Migration\Classification</job> + </post-migration> + </repair-steps> </info> diff --git a/apps/dav/appinfo/v1/publicwebdav.php b/apps/dav/appinfo/v1/publicwebdav.php index c6c319aa36d..261a4d4b96d 100644 --- a/apps/dav/appinfo/v1/publicwebdav.php +++ b/apps/dav/appinfo/v1/publicwebdav.php @@ -66,7 +66,6 @@ $server = $serverFactory->createServer($baseuri, $requestUri, $authBackend, func $share = $authBackend->getShare(); $owner = $share->getShareOwner(); - $isWritable = $share->getPermissions() & (\OCP\Constants::PERMISSION_UPDATE | \OCP\Constants::PERMISSION_CREATE); $isReadable = $share->getPermissions() & \OCP\Constants::PERMISSION_READ; $fileId = $share->getNodeId(); @@ -74,11 +73,9 @@ $server = $serverFactory->createServer($baseuri, $requestUri, $authBackend, func return false; } - if (!$isWritable) { - \OC\Files\Filesystem::addStorageWrapper('readonly', function ($mountPoint, $storage) { - return new \OC\Files\Storage\Wrapper\PermissionsMask(array('storage' => $storage, 'mask' => \OCP\Constants::PERMISSION_READ + \OCP\Constants::PERMISSION_SHARE)); - }); - } + \OC\Files\Filesystem::addStorageWrapper('sharePermissions', function ($mountPoint, $storage) use ($share) { + return new \OC\Files\Storage\Wrapper\PermissionsMask(array('storage' => $storage, 'mask' => $share->getPermissions() | \OCP\Constants::PERMISSION_SHARE)); + }); OC_Util::setupFS($owner); $ownerView = \OC\Files\Filesystem::getView(); |