diff options
author | Roeland Jago Douma <rullzer@users.noreply.github.com> | 2019-12-11 12:37:54 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-11 12:37:54 +0100 |
commit | 97deaf85b9d18cabfc345025ef273da24006c6de (patch) | |
tree | fbef8a1bc9026f9c7e967f7e6f87db630c6437b6 /apps/dav/lib/Connector | |
parent | c71e9de5ff3fe88d0798b70b5bde5caa03e51c3a (diff) | |
parent | 0f32f8119e1d27548732bb1468376959779c39cf (diff) | |
download | nextcloud-server-97deaf85b9d18cabfc345025ef273da24006c6de.tar.gz nextcloud-server-97deaf85b9d18cabfc345025ef273da24006c6de.zip |
Merge pull request #17935 from nextcloud/feature/noid/public-auth-for-circles
adding share type circles
Diffstat (limited to 'apps/dav/lib/Connector')
-rw-r--r-- | apps/dav/lib/Connector/PublicAuth.php | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/apps/dav/lib/Connector/PublicAuth.php b/apps/dav/lib/Connector/PublicAuth.php index 8732ae3b3c9..9e1771947da 100644 --- a/apps/dav/lib/Connector/PublicAuth.php +++ b/apps/dav/lib/Connector/PublicAuth.php @@ -34,6 +34,7 @@ use OCP\IRequest; use OCP\ISession; use OCP\Share\Exceptions\ShareNotFound; use OCP\Share\IManager; +use OCP\Share\IShare; use Sabre\DAV\Auth\Backend\AbstractBasic; /** @@ -97,7 +98,10 @@ class PublicAuth extends AbstractBasic { // check if the share is password protected if ($share->getPassword() !== null) { - if ($share->getShareType() === \OCP\Share::SHARE_TYPE_LINK || $share->getShareType() === \OCP\Share::SHARE_TYPE_EMAIL) { + + if ($share->getShareType() === IShare::TYPE_LINK + || $share->getShareType() === IShare::TYPE_EMAIL + || $share->getShareType() === IShare::TYPE_CIRCLE) { if ($this->shareManager->checkPassword($share, $password)) { return true; } else if ($this->session->exists('public_link_authenticated') @@ -112,7 +116,7 @@ class PublicAuth extends AbstractBasic { } return false; } - } else if ($share->getShareType() === \OCP\Share::SHARE_TYPE_REMOTE) { + } else if ($share->getShareType() === IShare::TYPE_REMOTE) { return true; } else { return false; |