Fix DB call for MySQL databases

This commit is contained in:
Thomas Citharel 2016-07-12 14:18:11 +02:00 committed by Lukas Reschke
parent 994001c480
commit aca305332a
No known key found for this signature in database
GPG Key ID: B9F6980CF6E759B1
1 changed files with 1 additions and 1 deletions

View File

@ -1560,7 +1560,7 @@ class CalDavBackend extends AbstractBackend implements SyncSupport, Subscription
*/
public function getPublishStatus($calendar) {
$query = $this->db->getQueryBuilder();
$result = $query->select('count(id)')
$result = $query->select($query->createFunction('COUNT(*)'))
->from('dav_shares')
->where($query->expr()->eq('resourceid', $query->createNamedParameter($calendar->getResourceId())))
->andWhere($query->expr()->eq('access', $query->createNamedParameter(self::ACCESS_PUBLIC)))