diff --git a/src/Api/Jobs/AbstractJob.php b/src/Api/Jobs/AbstractJob.php index bd2ebafb..1f65638b 100644 --- a/src/Api/Jobs/AbstractJob.php +++ b/src/Api/Jobs/AbstractJob.php @@ -1,10 +1,6 @@ getSubJobs() as $subJob) { - $subJob->setContext(AbstractJob::CONTEXT_BATCH_ADD); + $subJob->setContext(self::CONTEXT_BATCH_ADD); try { Api::run($subJob, $arguments); diff --git a/tests/Tests/ApiTests/ApiPrivilegeTest.php b/tests/Tests/ApiTests/ApiPrivilegeTest.php index 62097dfd..b58094b9 100644 --- a/tests/Tests/ApiTests/ApiPrivilegeTest.php +++ b/tests/Tests/ApiTests/ApiPrivilegeTest.php @@ -53,7 +53,7 @@ class ApiPrivilegeTest extends AbstractFullApiTest $ctx = function($job) { - $job->setContext(AbstractJob::CONTEXT_BATCH_ADD); + $job->setContext(IJob::CONTEXT_BATCH_ADD); return $job; }; $this->testDynamicPostPrivilege($ctx(new EditPostContentJob), Privilege::AddPostContent); @@ -139,7 +139,7 @@ class ApiPrivilegeTest extends AbstractFullApiTest $ctx = function($job) { - $job->setContext(AbstractJob::CONTEXT_BATCH_ADD); + $job->setContext(IJob::CONTEXT_BATCH_ADD); return $job; }; $this->testDynamicUserPrivilege($ctx(new EditUserAccessRankJob()), Privilege::EditUserAccessRank);