From cfc5af80928148844f0047c2974d57015645388a Mon Sep 17 00:00:00 2001 From: Ricardo Date: Fri, 27 Feb 2026 14:05:44 +0100 Subject: [PATCH] fix: rename tag template variable to hashtag to avoid Nunjucks macro collision The base layout default.njk imports a `tag` component macro which shadows the controller's `tag` variable in function/filter argument contexts. Renaming to `hashtag` eliminates the collision entirely. --- lib/controllers/tag-timeline.js | 2 +- package.json | 2 +- views/activitypub-tag-timeline.njk | 16 ++++++++-------- 3 files changed, 10 insertions(+), 10 deletions(-) diff --git a/lib/controllers/tag-timeline.js b/lib/controllers/tag-timeline.js index 7e5aeeb..cd0ac3d 100644 --- a/lib/controllers/tag-timeline.js +++ b/lib/controllers/tag-timeline.js @@ -132,7 +132,7 @@ export function tagTimelineController(mountPath) { response.render("activitypub-tag-timeline", { title: `#${tag}`, readerParent: { href: `${mountPath}/admin/reader`, text: response.locals.__("activitypub.reader.title") }, - tag, + hashtag: tag, items, before: result.before, after: result.after, diff --git a/package.json b/package.json index 70086c5..8ab61b7 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@rmdes/indiekit-endpoint-activitypub", - "version": "2.0.34", + "version": "2.0.35", "description": "ActivityPub federation endpoint for Indiekit via Fedify. Adds full fediverse support: actor, inbox, outbox, followers, following, syndication, and Mastodon migration.", "keywords": [ "indiekit", diff --git a/views/activitypub-tag-timeline.njk b/views/activitypub-tag-timeline.njk index 15f1222..5c5703a 100644 --- a/views/activitypub-tag-timeline.njk +++ b/views/activitypub-tag-timeline.njk @@ -4,7 +4,7 @@ {# Tag header #}
-

#{{ tag }}

+

#{{ hashtag }}

{{ __("activitypub.reader.tagTimeline.postsTagged", items.length) }}

@@ -13,7 +13,7 @@ {% if isFollowed %}