Merge pull request #468 from nextcloud/stringid-fix

Cast share id to string (#25402)
This commit is contained in:
Roeland Douma 2016-07-20 20:06:46 +02:00 committed by GitHub
commit ffc345b141
1 changed files with 1 additions and 1 deletions

View File

@ -98,7 +98,7 @@ class PublicAuth extends AbstractBasic {
if ($this->shareManager->checkPassword($share, $password)) { if ($this->shareManager->checkPassword($share, $password)) {
return true; return true;
} else if ($this->session->exists('public_link_authenticated') } else if ($this->session->exists('public_link_authenticated')
&& $this->session->get('public_link_authenticated') === $share->getId()) { && $this->session->get('public_link_authenticated') === (string)$share->getId()) {
return true; return true;
} else { } else {
if (in_array('XMLHttpRequest', explode(',', $this->request->getHeader('X-Requested-With')))) { if (in_array('XMLHttpRequest', explode(',', $this->request->getHeader('X-Requested-With')))) {