diff --git a/app/library/App/Controllers/GaController.php b/app/library/App/Controllers/GaController.php index 28076c6..1755f57 100644 --- a/app/library/App/Controllers/GaController.php +++ b/app/library/App/Controllers/GaController.php @@ -41,7 +41,9 @@ class GaController extends CrudResourceController { $projects = Project::find(['user_id' => $user_id]); foreach ($projects as $project) { $view_id = (string)$project->ga_view_id; - $result[] = $this->sendGaRequest($project->name, $view_id, $get_metrics, $get_dimensions, $get_start_date, $get_end_date, $chart); + if (!empty($view_id)) { + $result[] = $this->sendGaRequest($project->name, $view_id, $get_metrics, $get_dimensions, $get_start_date, $get_end_date, $chart); + } } } else { -- libgit2 0.21.4