stackernews / stacker.news

Internet communities that pay you Bitcoin
https://stacker.news
MIT License
404 stars 105 forks source link

Pinned posts don't show "Related Posts" #1148

Closed SatsAllDay closed 1 month ago

SatsAllDay commented 1 month ago

Description Posts that are pinned to a territory don't show "Related Posts" in the full item UI.

Steps to Reproduce

  1. Navigate to a post that is pinned to a territory
  2. Observer no Related posts
  3. Example

Expected behavior Posts should show related posts, even if they're pinned.

Screenshots Self-explanatory

Logs N/A

Environment: N/A

Additional context As discussed here, there is a check in the code to hide the "Related Posts" section in the UI, if the item.position value is truthy. This was added to hide "Related Posts" from the Saloon daily posts. However, it has the unintended side effect of hiding "Related Posts" from all pinned posts.

We should be able to change this AND condition to (!item.position && !item.subName) (note the parenthesis) here.