Some generic code refactoring.

This commit is contained in:
James Cole
2019-06-21 19:10:02 +02:00
parent fb1af395f9
commit 2d3d7f7720
67 changed files with 920 additions and 603 deletions

View File

@@ -56,7 +56,7 @@ class SpectreRoutine implements RoutineInterface
{
Log::debug(sprintf('Now in SpectreRoutine::run() with status "%s" and stage "%s".', $this->importJob->status, $this->importJob->stage));
$valid = ['ready_to_run']; // should be only ready_to_run
if (\in_array($this->importJob->status, $valid, true)) {
if (in_array($this->importJob->status, $valid, true)) {
switch ($this->importJob->stage) {
default:
throw new FireflyException(sprintf('SpectreRoutine cannot handle stage "%s".', $this->importJob->stage)); // @codeCoverageIgnore