diff --git a/app/Http/Controllers/DashboardController.php b/app/Http/Controllers/DashboardController.php index af1c9b4d..35ed6fc0 100644 --- a/app/Http/Controllers/DashboardController.php +++ b/app/Http/Controllers/DashboardController.php @@ -22,7 +22,7 @@ class DashboardController extends Controller { $reports = $this->getlambda('get', 'metric', 'metric_report', 'list'); $widgets = $this->getlambda('get', 'wall', 'widgets', 'list'); - return view('index')->with(['metrics' => $reports->data->metrics, 'widgets' => $widgets->data->widgets]); + return view('index')->with(['metrics' => isset($reports->data->metrics) ? $reports->data->metrics : [], 'widgets' => $widgets->data->widgets]); }