]> source.dussan.org Git - nextcloud-server.git/commitdiff
Fix DB call for MySQL databases
authorThomas Citharel <tcit@tcit.fr>
Tue, 12 Jul 2016 12:18:11 +0000 (14:18 +0200)
committerLukas Reschke <lukas@statuscode.ch>
Mon, 26 Sep 2016 09:55:37 +0000 (11:55 +0200)
apps/dav/lib/CalDAV/CalDavBackend.php

index a134cba348ef22d296c24e1a0cf3b1132f20d316..62f5213e34f205959380963f7e62434defa6a20b 100644 (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)))