From ca0f7b41821b58a948ab8afb4fb9397a5d6ce913 Mon Sep 17 00:00:00 2001 From: Dmitry Khomutov Date: Wed, 11 Oct 2017 18:55:03 +0700 Subject: [PATCH] Fixed schedule build command. Issue #125. --- src/PHPCensor/Command/ScheduleBuildCommand.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/PHPCensor/Command/ScheduleBuildCommand.php b/src/PHPCensor/Command/ScheduleBuildCommand.php index aeeadee7..69d89270 100644 --- a/src/PHPCensor/Command/ScheduleBuildCommand.php +++ b/src/PHPCensor/Command/ScheduleBuildCommand.php @@ -69,7 +69,8 @@ class ScheduleBuildCommand extends Command $difference = new \DateInterval("P{$sinceDays}D"); $date->sub($difference); - $projects = $this->projectStore->getAll()['items']; + $projects = $this->projectStore->getAll(); + $projects = $projects['items']; /** @var Project $project */ foreach ($projects as $project) { $latestBuild = $this->buildStore->getLatestBuilds($project->getId(), 1);