From 302717bad090b2eecb05545bccd7998de8a33015 Mon Sep 17 00:00:00 2001 From: Dan Cryer Date: Fri, 9 May 2014 12:16:24 +0100 Subject: [PATCH] Cleaning up exceptions in the BuildStatus controller --- PHPCI/Controller/BuildStatusController.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/PHPCI/Controller/BuildStatusController.php b/PHPCI/Controller/BuildStatusController.php index 74a1fbad..8c34cd63 100644 --- a/PHPCI/Controller/BuildStatusController.php +++ b/PHPCI/Controller/BuildStatusController.php @@ -65,7 +65,8 @@ class BuildStatusController extends \PHPCI\Controller public function view($projectId) { $project = $this->projectStore->getById($projectId); - if (!$project) { + + if (empty($project)) { throw new NotFoundException('Project with id: ' . $projectId . ' not found'); }