From: Joas Schilling Date: Wed, 2 Mar 2022 08:23:16 +0000 (+0100) Subject: Also use hashed/indexed column on delete X-Git-Tag: v24.0.0beta1~134^2 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=refs%2Fpull%2F31398%2Fhead;p=nextcloud-server.git Also use hashed/indexed column on delete Signed-off-by: Joas Schilling --- diff --git a/lib/private/BackgroundJob/JobList.php b/lib/private/BackgroundJob/JobList.php index 16dfa7b58a6..67caea62af0 100644 --- a/lib/private/BackgroundJob/JobList.php +++ b/lib/private/BackgroundJob/JobList.php @@ -111,8 +111,8 @@ class JobList implements IJobList { $query->delete('jobs') ->where($query->expr()->eq('class', $query->createNamedParameter($class))); if (!is_null($argument)) { - $argument = json_encode($argument); - $query->andWhere($query->expr()->eq('argument', $query->createNamedParameter($argument))); + $argumentJson = json_encode($argument); + $query->andWhere($query->expr()->eq('argument_hash', $query->createNamedParameter(md5($argumentJson)))); } $query->execute(); }