| Total Complexity | 3 |
| Total Lines | 22 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 5 | class LaravelSeoMetaBox |
||
| 6 | { |
||
| 7 | private array $objectsOnPage = []; |
||
| 8 | |||
| 9 | public function addObjectOnPage(string $type, int $id): void |
||
| 10 | { |
||
| 11 | $this->objectsOnPage[] = [ |
||
| 12 | 'type' => $type, |
||
| 13 | 'id' => $id, |
||
| 14 | ]; |
||
| 15 | } |
||
| 16 | |||
| 17 | /** |
||
| 18 | * Retrieve the last object added to the page that can have Seo. |
||
| 19 | */ |
||
| 20 | public function getObjectOnPage(): ?array |
||
| 27 | } |
||
| 28 | } |
||
| 29 |