]> git.mxchange.org Git - friendica.git/blobdiff - src/Core/Worker.php
Merge pull request #11258 from MrPetovan/bug/11234-categories-profile
[friendica.git] / src / Core / Worker.php
index 8dd1ece8e5e41ada1cc0bfb4a9ed85de59ce219a..d43d8c7281008198beac9b812ee9bd160fbf9d56 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * @copyright Copyright (C) 2010-2021, the Friendica project
+ * @copyright Copyright (C) 2010-2022, the Friendica project
  *
  * @license GNU AGPL version 3 or any later version
  *
@@ -754,7 +754,7 @@ class Worker
                                        }
 
                                        $stamp = (float)microtime(true);
-                                       $jobs = DBA::count('workerqueue', ["`done` AND `executed` > UTC_TIMESTAMP() - INTERVAL ? MINUTE", $interval]);
+                                       $jobs = DBA::count('workerqueue', ["`done` AND `executed` > ?", DateTimeFormat::utc('now - ' . $interval . ' minute')]);
                                        self::$db_duration += (microtime(true) - $stamp);
                                        self::$db_duration_stat += (microtime(true) - $stamp);
                                        $jobs_per_minute[$interval] = number_format($jobs / $interval, 0);