Skip to content

Commit

Permalink
Prevent error if integration is not configured/enabled.
Browse files Browse the repository at this point in the history
  • Loading branch information
heathdutton committed May 30, 2018
1 parent c4ff497 commit 732c590
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Model/HealthModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,10 @@ public function getIncidents()
*/
public function reportIncidents(OutputInterface $output = null)
{
if ($this->integration && $this->incidents && !empty($this->settings['statuspage_component_id'])) {
if (!$this->integration) {
return;
}
if ($this->incidents && !empty($this->settings['statuspage_component_id'])) {
$name = 'Degraded Performance';
$body = [];
foreach ($this->incidents as $campaignId => $campaign) {
Expand Down

0 comments on commit 732c590

Please sign in to comment.