Skip to content

Commit

Permalink
Merge pull request #135 from itnova/master
Browse files Browse the repository at this point in the history
Fix cron groups in default cron. Relates to issue #130
  • Loading branch information
LeeSaferite committed Jul 10, 2015
2 parents 5684052 + fb2ddf8 commit 3d16b7c
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions shell/scheduler.php
Original file line number Diff line number Diff line change
Expand Up @@ -349,11 +349,18 @@ public function cronAction()
switch ($mode) {
case 'always':
case 'default':
$includeGroups = array_filter(array_map('trim', explode(',', $this->getArg('include'))));
$excludeGroups = array_filter(array_map('trim', explode(',', $this->getArg('exclude'))));
$includeGroups = array_filter(array_map('trim', explode(',', $this->getArg('includeGroups'))));
$excludeGroups = array_filter(array_map('trim', explode(',', $this->getArg('excludeGroups'))));
$includeJobs = array_filter(array_map('trim', explode(',', $this->getArg('includeJobs'))));
$excludeJobs = array_filter(array_map('trim', explode(',', $this->getArg('excludeJobs'))));
Mage::getConfig()->init()->loadEventObservers('crontab');
Mage::app()->addEventArea('crontab');
Mage::dispatchEvent($mode, array('include' => $includeGroups, 'exclude' => $excludeGroups));
Mage::dispatchEvent($mode, array(
'include_groups' => $includeGroups,
'exclude_groups' => $excludeGroups,
'include_jobs' => $includeJobs,
'exclude_jobs' => $excludeJobs,
));
break;
default:
echo "\nInvalid mode!\n\n";
Expand Down

0 comments on commit 3d16b7c

Please sign in to comment.