24 $productsFromVk = $apiHelper->getProductsFromVk($this->vkGroupId);
25 $productsMapped = Vk\Map::getMappedProducts($this->exportId);
28 $productsMappedToRemove = array();
29 foreach ($productsMapped as $productMapped)
30 $productsMappedToRemove[] = array(
"VALUE_EXTERNAL" => $productMapped[
"VK_ID"]);
32 if (!empty($productsMappedToRemove))
33 Vk\Map::removeProductMapping($productsMappedToRemove, $this->exportId);
36 $productsFromVk = Vk\Api\ApiHelper::extractItemsFromArray($productsFromVk, array(
"VK_ID"));
38 foreach ($productsFromVk as $chunk)
40 $this->executer->executeMarketProductDelete(array(
41 "owner_id" => $this->vkGroupId,
43 "count" => count($chunk),
47 if ($timer !== NULL && !$timer->check())
53 $vkExportedData->removeData();