diff options
author | (quasar) nebula <qznebula@protonmail.com> | 2024-04-23 15:47:31 -0300 |
---|---|---|
committer | (quasar) nebula <qznebula@protonmail.com> | 2024-05-30 20:48:17 -0300 |
commit | ad03579e658d15aecc6f9bda693ec6995c9fa8ae (patch) | |
tree | 02bf0cd63b6903914c46e1f637bf8631fc961fb6 | |
parent | 38cba5da6e8e8e06e242a48854c8aacd3d32e2a9 (diff) |
content: generateChronologyLinks: filter no prev/next properly
-rw-r--r-- | src/content/dependencies/generateChronologyLinks.js | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/content/dependencies/generateChronologyLinks.js b/src/content/dependencies/generateChronologyLinks.js index 0158ffd5..bd798849 100644 --- a/src/content/dependencies/generateChronologyLinks.js +++ b/src/content/dependencies/generateChronologyLinks.js @@ -33,8 +33,14 @@ export default { if (!slots.showOnly) { infoSets = infoSets - .filter(({nextLink, previousLink}) => - nextLink || previousLink); + .map(({contributions, ...entry}) => ({ + ...entry, + contributions: + contributions + .filter(({nextLink, previousLink}) => + nextLink || previousLink), + })) + .filter(({contributions}) => !empty(contributions)); } const totalContributionCount = |