Skip to content

Commit

Permalink
limit title/h1/metaDesc size
Browse files Browse the repository at this point in the history
  • Loading branch information
RobinDev committed Sep 4, 2023
1 parent 8feb0f0 commit 1893630
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/crawler/src/Url.php
Expand Up @@ -426,7 +426,7 @@ public function getTitle(): string

public function setTitle(string $title): void
{
$this->title = $title;
$this->title = substr($title, 0, 300);
}

public function getUpdatedAt(): \DateTimeInterface
Expand Down Expand Up @@ -589,7 +589,7 @@ public function getMetaDescription(): string

public function setMetaDescription(string $metaDescription): void
{
$this->metaDescription = $metaDescription;
$this->metaDescription = substr($metaDescription, 0, 300);
}

public function getH1(): string
Expand All @@ -599,7 +599,7 @@ public function getH1(): string

public function setH1(string $h1): void
{
$this->h1 = $h1;
$this->h1 = substr($h1, 0, 300);
}

/**
Expand Down

0 comments on commit 1893630

Please sign in to comment.