config = $config; $this->usageStatisticCollector = $usageStatisticCollector; $this->usageStatisticSender = $usageStatisticSender; $this->getEnabledStoresUrls = $getEnabledStoresUrls; } /** * @return bool */ public function execute(): bool { return false; // TODO: uncomment after create api if (! $this->config->isEnabledStatistic()) { return false; } if ($usageData = $this->usageStatisticCollector->collect()) { return $this->usageStatisticSender->send( [ 'storesUrls' => $this->getEnabledStoresUrls->execute(), 'modules' => $usageData, ] ); } return false; } }