Skip to content

Commit

Permalink
fix: Generate correct links to tags in Atom feeds
Browse files Browse the repository at this point in the history
In the feeds, the links to tags were in the form of `/links?q=#tag`.
Most of the aggregators are able to rebuild the correct link by using
the feed domain as the base URL. But it didn't work when the feeds were
generated with the `direct=true` parameter because the base URL wasn't
the one to Flus.

Now, the tags links are always generated in an absolute form to avoid
this issue (even in the interface because it was easier to patch).
  • Loading branch information
marienfressinaud committed Nov 1, 2024
1 parent 8d36730 commit ccbcbbc
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils/MiniMarkdown.php
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ protected function inlineTag(array $excerpt): ?array

if ($result) {
$tag = $matches['tag'];
$tag_url = \Minz\Url::for('links', [
$tag_url = \Minz\Url::absoluteFor('links', [
'q' => "#{$tag}",
]);

Expand Down

0 comments on commit ccbcbbc

Please sign in to comment.