Fix the view composer, don't poorly check incident statuses
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
->groupBy('status')
|
||||
->orderBy('status', 'desc');
|
||||
|
||||
if ($incidents->count() === 0 || (int) $incidents->first()->status === 4) {
|
||||
if ($incidents->get()->count() === 1 || (int) $incidents->first()->status === 4) {
|
||||
$status = 'success';
|
||||
$message = 'All systems are functional.';
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user