fedipod-bb 0.5.0 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/site/robots.txt +2 -0
- package/src/render.mjs +3 -0
package/package.json
CHANGED
package/site/robots.txt
ADDED
package/src/render.mjs
CHANGED
|
@@ -52,6 +52,9 @@ function fill(shell, { title, description, forumName, forumHref, modsLine, acts,
|
|
|
52
52
|
async function draw(url, shell, f) {
|
|
53
53
|
const place = placeOf({ origin: url.origin, pathname: url.pathname, search: '' });
|
|
54
54
|
if (!place.own || !place.root || !place.base) return null;
|
|
55
|
+
// Drawn: the front page, a category, a topic. Any other address under the
|
|
56
|
+
// forum is the page's own to build.
|
|
57
|
+
if (!/^(?:c\/[^/]+|t\/[^/]+\/[^/]+)?\/?$/u.test(url.pathname.slice(place.root.length))) return null;
|
|
55
58
|
const view = viewOfPath(url.pathname, place.root);
|
|
56
59
|
const read = reader({ fetch: f, at: AT });
|
|
57
60
|
const forum = await read.forum(place.base);
|