summaryrefslogtreecommitdiffstats
path: root/lib/private/Files/Cache/Propagator.php
diff options
context:
space:
mode:
authorJoas Schilling <coding@schilljs.com>2020-11-06 08:44:46 +0100
committerJoas Schilling <coding@schilljs.com>2020-11-06 12:13:22 +0100
commit4b125d4402df502eb2cb79d65e6a11d39262b15e (patch)
tree28181aed725fd4aaa0f73300c82867f6d9ef7dd6 /lib/private/Files/Cache/Propagator.php
parent3c027bd0cf698ab573e4b92fbeeccd929c2beb19 (diff)
downloadnextcloud-server-4b125d4402df502eb2cb79d65e6a11d39262b15e.tar.gz
nextcloud-server-4b125d4402df502eb2cb79d65e6a11d39262b15e.zip
Use Query builder function
Signed-off-by: Joas Schilling <coding@schilljs.com>
Diffstat (limited to 'lib/private/Files/Cache/Propagator.php')
-rw-r--r--lib/private/Files/Cache/Propagator.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/private/Files/Cache/Propagator.php b/lib/private/Files/Cache/Propagator.php
index 53e56c37735..97eaa839ccf 100644
--- a/lib/private/Files/Cache/Propagator.php
+++ b/lib/private/Files/Cache/Propagator.php
@@ -168,7 +168,7 @@ class Propagator implements IPropagator {
$storageId = (int)$this->storage->getStorageCache()->getNumericId();
$query->update('filecache')
- ->set('mtime', $query->createFunction('GREATEST(' . $query->getColumnName('mtime') . ', ' . $query->createParameter('time') . ')'))
+ ->set('mtime', $query->func()->greatest('mtime', $query->createParameter('time')))
->set('etag', $query->expr()->literal(uniqid()))
->where($query->expr()->eq('storage', $query->expr()->literal($storageId, IQueryBuilder::PARAM_INT)))
->andWhere($query->expr()->eq('path_hash', $query->createParameter('hash')));