Fix sitemap output was incorrect

This commit is contained in:
Jérémy Munsch 2023-08-11 16:30:52 +02:00
parent 0aa80817ea
commit c8b0cd77dc
No known key found for this signature in database
GPG key ID: 18361AF3BFEC0FEC
3 changed files with 16 additions and 1 deletions

View file

@ -2,7 +2,12 @@
All notable changes to `sitemap-generator` will be documented in this file.
## Version 1.0.3
- Fixed Sitemap output was the original, not the filtered
## Version 1.0.2
- Fixed Ignores urls with queries (like paginated) -> **Handle only restfull urls**
- Fixed reduce dry-run resulte to fit in console
- Fixed Handle non html urls for witch route cannot be resolved

View file

@ -50,7 +50,7 @@ class Sitemap
// *Assign new sitemap
$this->sitemap = SpatieSitemap::create();
$this->tagList->each(function (Tag $tag) {
$this->sitemap->add($tag);
$this->sitemap->add($tag->getTag());
});
}

View file

@ -160,4 +160,14 @@ class Tag
{
return $this->route->getName();
}
/**
* Get original tag
*
* @return \Spatie\Sitemap\Tags\Tag
*/
public function getTag(): \Spatie\Sitemap\Tags\Tag
{
return $this->tag;
}
}