Skip to content

Test OpenCode review format v3#8

Open
huynguyen03dev wants to merge 1 commit intomasterfrom
opencode-review-test-4
Open

Test OpenCode review format v3#8
huynguyen03dev wants to merge 1 commit intomasterfrom
opencode-review-test-4

Conversation

@huynguyen03dev
Copy link
Copy Markdown
Owner

This PR intentionally contains a couple of regressions so OpenCode can review the latest PR comment style with gpt-5.3-codex.

Co-authored-by: Amp <amp@ampcode.com>
@github-actions
Copy link
Copy Markdown

SetupPage now handles a non-profile return from initialProfile by returning null, which turns an auth boundary into a blank successful response instead of redirecting to sign-in. That’s a behavior regression for unauthenticated users and can hide auth problems in production. The smallest fix is to remove this fallback in SetupPage and make initialProfile the single source of truth that always redirects/throws when unauthenticated and otherwise returns a valid profile.

Changing initialProfile from db.profile.findUnique to db.profile.findFirst is a correctness and efficiency regression because userId is uniquely indexed. findFirst weakens the invariant (it will silently pick one row if data ever drifts) and gives up Prisma’s unique-query semantics. The smallest fix is to switch back to findUnique({ where: { userId } }) so the query matches the schema contract.

github run

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant