Skip to content

Commit

Permalink
Don't try to delete a cronjob if does'nt exist
Browse files Browse the repository at this point in the history
* solve #44
  • Loading branch information
camlafit committed Nov 30, 2018
1 parent 48869f7 commit f6010fc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cronjobs.php
Expand Up @@ -525,7 +525,7 @@ public function addNewModulesTasks()
$id_module = (int)$cron['id_module'];
$module = Module::getInstanceById((int)$cron['id_module']);

if ($module == false) {
if ($module == false && isset($cron['id_cronjob'])) {
Db::getInstance()->execute('DELETE FROM '._DB_PREFIX_.bqSQL($this->name).' WHERE `id_cronjob` = \''.(int)$cron['id_cronjob'].'\'');
break;
}
Expand Down

0 comments on commit f6010fc

Please sign in to comment.