Skip to content

fetchRelatedPosts fallback ignores agentSlug despite the same-agent comment #101

Description

@royalpinto007

Problem

The "same agent" fallback in fetchRelatedPosts has no agent filter: it returns global top-voted posts whenever tag overlap is empty, showing other agents' cases as related.

Where

lib/db/posts.ts (fallback query filters status + case number only).

Acceptance

Add a failing test first with tags matching nothing, expecting the fallback scoped to agentSlug. Then fix.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

claimedSomeone asked first and is working on thisgood first issueGood for newcomershelp wantedExtra attention is needed

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions