Skip to content

Commit a95a1f3

Browse files
committed
FIX: Status Command
1 parent c1d82ab commit a95a1f3

File tree

2 files changed

+4
-10
lines changed

2 files changed

+4
-10
lines changed

src/Command/StatusCommand.php

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -61,9 +61,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
6161
//====================================================================//
6262
// Load Tasks Repository
6363
/** @var TaskRepository $repo */
64-
$repo = $this->getContainer()
65-
->get("doctrine")->getManager()
66-
->getRepository(Task::class);
64+
$repo = $this->getContainer()->get("splash.tasking.tasks")->getTasksRepository();
6765

6866
while (1) {
6967
//====================================================================//
@@ -108,9 +106,7 @@ protected function showWorkers(OutputInterface $output): void
108106
//====================================================================//
109107
// Load Tasks Repository
110108
/** @var WorkerRepository $repo */
111-
$repo = $this->getContainer()
112-
->get("doctrine")->getManager()
113-
->getRepository(Worker::class);
109+
$repo = $this->getContainer()->get("splash.tasking.tasks")->getWorkerRepository();
114110

115111
//====================================================================//
116112
// List Workers Status
@@ -156,9 +152,7 @@ protected function getWorkersStatusStr()
156152
//====================================================================//
157153
// Load Worker Repository
158154
/** @var WorkerRepository $workers */
159-
$workers = $this->getContainer()
160-
->get("doctrine")->getManager()
161-
->getRepository(Worker::class);
155+
$workers = $this->getContainer()->get("splash.tasking.tasks")->getWorkerRepository();
162156
//====================================================================//
163157
// Fetch Workers Status
164158
$status = $workers->getWorkersStatus();

src/Command/StopCommand.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ protected function execute(InputInterface $input, OutputInterface $output)
8484
// Setup TimeOut for this operation
8585
$this->setupTimeout();
8686
//====================================================================//
87-
// Count Total Number of Wrokers
87+
// Count Total Number of Workers
8888
$total = $this->manager->countActiveWorkers();
8989
//====================================================================//
9090
// Track Workers are Stopped

0 commit comments

Comments
 (0)