Skip to content

Commit

Permalink
Update rake support disable crawl link in the content
Browse files Browse the repository at this point in the history
  • Loading branch information
puleeno committed Dec 30, 2022
1 parent 1f9c9c2 commit 9121256
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/Constracts/Tooth.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ public function addMappingField($fieldName, $mappingRules);

public function addFeed(Feed $feed);

public function isTransferResources();

public function downloadResource(Resource &$resource): Resource;

public function validateSystemResource($newGuid, $newType): bool;
Expand Down
9 changes: 8 additions & 1 deletion src/Rake.php
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,10 @@ public function execute()
}
}

/**
* @param \Ramphor\Rake\Constracts\Tooth $tooth
* @param \Ramphor\Rake\ProcessResult[] $results
*/
public function sync($tooth, $results)
{
foreach ($results as $result) {
Expand All @@ -232,7 +236,10 @@ public function sync($tooth, $results)
// Import resources
$resources = Resources::createFromResult($result, $tooth);
$resources->import(true);
$resources->importCrawlUrls();

if ($tooth->isCrawlUrlInContent()) {
$resources->importCrawlUrls();
}

// Transfer the resources are fetched from the feed
if ($tooth->isTransferResources()) {
Expand Down

0 comments on commit 9121256

Please sign in to comment.