Skip to content

fix: show the claimant their own claim, not the loser's message - #741

Open
smartcalsystems-sketch wants to merge 1 commit into
MergeFi:mainfrom
smartcalsystems-sketch:fix-claimbutton-own-claim-state-699
Open

smartcalsystems-sketch wants to merge 1 commit into
MergeFi:mainfrom
smartcalsystems-sketch:fix-claimbutton-own-claim-state-699

Conversation

@smartcalsystems-sketch

Copy link
Copy Markdown

Problem

When status === 'claimed', ClaimButton shows "This bounty has already been claimed" / "Claimed by: …" to everyone, including the claimant — after the 5s success notice expires, or on any later visit. The person doing the work gets wording meant for losers of the race, and no "Open a pull request that says Fixes #N" guidance.

Fix

Compares bounty.claimedById with user.id. When they match, renders a distinct "You're working on this" panel with the specific Fixes #<issueNumber> instruction and a note that the reward releases automatically on merge. Everyone else (a different signed-in user, or a signed-out visitor) still sees the existing generic already-claimed view unchanged.

Testing

  • Added 3 tests: the claimant sees the new "You're working on this" panel with the correct issue number; a different signed-in user still sees the generic view; a signed-out visitor still sees the generic view.
  • Full ClaimButton.test.tsx suite: 24/24 passing (21 pre-existing + 3 new), zero regressions.
  • tsc --noEmit and eslint clean on both changed files.

Closes #699

MergeFi#699)

When status === 'claimed', ClaimButton showed "This bounty has already
been claimed" / "Claimed by: ..." to everyone, including the person who
claimed it -- once the 5s success notice expires, or on any later visit,
the contributor doing the work sees wording written for the people who
lost the race, with no guidance on what to do next.

Compare bounty.claimedById against user.id: the claimant now sees a
distinct "You're working on this" panel with the Fixes #N PR
instruction, while everyone else (a different signed-in user, or signed
out) still sees the existing generic already-claimed view.
@vercel

vercel Bot commented Oct 13, 2026

Copy link
Copy Markdown

@smartcalsystems-sketch is attempting to deploy a commit to the chonilius' projects Team on Vercel.

A member of the Team first needs to authorize it.

This branch has not been deployed

No deployments
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.

The contributor who claimed a bounty sees 'This bounty has already been claimed' with no next steps

1 participant