Fix datapolicycron

This commit is contained in:
ptibogxiv 2020-05-15 01:18:53 +02:00 committed by GitHub
parent 92b245ae93
commit cb98ec4d23
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -470,15 +470,15 @@ class DataPolicyCron
{ {
$sql = sprintf($params['sql'], (int) $conf->entity, (int) $conf->global->$key, (int) $conf->global->$key); $sql = sprintf($params['sql'], (int) $conf->entity, (int) $conf->global->$key, (int) $conf->global->$key);
$resql = $db->query($sql); $resql = $this->db->query($sql);
if ($resql && $db->num_rows($resql) > 0) if ($resql && $this->db->num_rows($resql) > 0)
{ {
$num = $db->num_rows($resql); $num = $this->db->num_rows($resql);
$i = 0; $i = 0;
require_once $params['file']; require_once $params['file'];
$object = new $params['class']($db); $object = new $params['class']($this->db);
while ($i < $num && ! $error) while ($i < $num && ! $error)
{ {